[ASTableNode] expose ASTableView's -visibleNodes (#2449)

* expose ASTableView's -visibleNodes getter at the ASTableNode level

* add safegaurds

* make visibleNodes a read only property for ASTableNode

* make collectionNode .visibleNodes property
This commit is contained in:
Hannah Troisi
2016-10-24 09:42:04 -07:00
committed by Adlai Holler
parent 3638feffd4
commit 97e23776e4
4 changed files with 17 additions and 3 deletions

View File

@@ -339,6 +339,13 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (NSInteger)tableNode:(ASTableNode *)tableNode numberOfRowsInSection:(NSInteger)section;
/**
* Similar to -visibleCells.
*
* @return an array containing the nodes being displayed on screen. This must be called on the main thread.
*/
@property(readonly, copy) NSArray<__kindof ASCellNode *> *visibleNodes;
/**
* Asks the data source for a block to create a node to represent the row at the given index path.
* The block will be run by the table node concurrently in the background before the row is inserted