Swiftgram/AsyncDisplayKit/Details/ASIndexedNodeContext.h
Huy Nguyen 54cde1a3db Introduce ASIndexedNodeContext
- It is a container object that holds enough information to construct and measure a cell node
- All information is gathered on main thread. This allows ASDataController to capture the correct state of its data source before going to background.
2016-02-29 01:00:16 -08:00

23 lines
669 B
Objective-C

//
// ASIndexedNodeContext.h
// AsyncDisplayKit
//
// Created by Huy Nguyen on 2/28/16.
// Copyright © 2016 Facebook. All rights reserved.
//
#import <AsyncDisplayKit/ASDataController.h>
#import <AsyncDisplayKit/ASDimension.h>
@interface ASIndexedNodeContext : NSObject
@property (nonatomic, readonly, strong) ASCellNodeBlock nodeBlock;
@property (nonatomic, readonly, assign) NSIndexPath *indexPath;
@property (nonatomic, readonly, assign) ASSizeRange constrainedSize;
- (instancetype)initWithNodeBlock:(ASCellNodeBlock)nodeBlock
indexPath:(NSIndexPath *)indexPath
constrainedSize:(ASSizeRange)constrainedSize;
@end