IGListSectionController

@interface IGListSectionController : NSObject

The base class for section controllers used in the list infra. This class is meant to be subclassed.

  • The view controller housing the adapter that created this section controller.

    @discussion Use this view controller to push, pop, present, or do other custom transitions. It is considered very bad practice to cast this to a known view controller and call methods on it other than for navigations and transitions.

    Declaration

    Objective-C

    @property (readonly, nonatomic, nullable) UIViewController *viewController;
  • A context object for interacting with the collection i.e. accessing the collection size, dequeing cells, reloading/inserting/deleting, etc.

    Declaration

    Objective-C

    @property (readonly, nonatomic, nullable) id<IGListCollectionContext>
        collectionContext;

    Swift

    weak var collectionContext: AnyObject? { get }
  • The margins used to lay out content in the section controller.

    See

    -[UICollectionViewFlowLayout sectionInset]

    Declaration

    Objective-C

    @property (assign, readwrite, nonatomic) UIEdgeInsets inset;

    Swift

    var inset: Int32 { get set }
  • The minimum spacing to use between rows of items.

    See

    -[UICollectionViewFlowLayout minimumLineSpacing]

    Declaration

    Objective-C

    @property (assign, readwrite, nonatomic) CGFloat minimumLineSpacing;

    Swift

    var minimumLineSpacing: Int32 { get set }
  • The minimum spacing to use between items in the same row.

    See

    -[UICollectionViewFlowLayout minimumInteritemSpacing]

    Declaration

    Objective-C

    @property (assign, readwrite, nonatomic) CGFloat minimumInteritemSpacing;

    Swift

    var minimumInteritemSpacing: Int32 { get set }
  • The supplementary view source for the section controller. Can be nil.

    @discussion You may wish to return self if your section controller implements this protocol.

    Declaration

    Objective-C

    @property (readwrite, nonatomic, nullable) id<IGListSupplementaryViewSource>
        supplementaryViewSource;

    Swift

    weak var supplementaryViewSource: AnyObject? { get set }

    Return Value

    An object that conforms to IGListSupplementaryViewSource or nil.

  • An object that handles display events for the section controller. Can be nil.

    @discussion You may wish to return self if your section controller implements this protocol.

    Declaration

    Objective-C

    @property (readwrite, nonatomic, nullable) id<IGListDisplayDelegate>
        displayDelegate;

    Swift

    weak var displayDelegate: AnyObject? { get set }

    Return Value

    An object that conforms to IGListDisplayDelegate or nil.

  • An object that handles working range events for the section controller. Can be nil.

    @discussion You may wish to return self if your section controller implements this protocol.

    Declaration

    Objective-C

    @property (readwrite, nonatomic, nullable) id<IGListWorkingRangeDelegate>
        workingRangeDelegate;

    Swift

    weak var workingRangeDelegate: AnyObject? { get set }

    Return Value

    An object that conforms to IGListWorkingRangeDelegate or nil.

  • An object that handles display events for the section controller. Can be nil.

    @discussion You may wish to return self if your section controller implements this protocol.

    Declaration

    Objective-C

    @property (readwrite, nonatomic, nullable) id<IGListScrollDelegate>
        scrollDelegate;

    Swift

    weak var scrollDelegate: AnyObject? { get set }

    Return Value

    An object that conforms to IGListDisplayDelegate or nil.