Swiftgram/AsyncDisplayKit/Details/ASIndexedNodeContext.m
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

27 lines
566 B
Objective-C

//
// ASIndexedNodeContext.m
// AsyncDisplayKit
//
// Created by Huy Nguyen on 2/28/16.
// Copyright © 2016 Facebook. All rights reserved.
//
#import "ASIndexedNodeContext.h"
@implementation ASIndexedNodeContext
- (instancetype)initWithNodeBlock:(ASCellNodeBlock)nodeBlock
indexPath:(NSIndexPath *)indexPath
constrainedSize:(ASSizeRange)constrainedSize;
{
self = [super init];
if (self) {
_nodeBlock = nodeBlock;
_indexPath = indexPath;
_constrainedSize = constrainedSize;
}
return self;
}
@end