Trait objc2_app_kit::NSCollectionViewDataSource

source ·
pub unsafe trait NSCollectionViewDataSource: NSObjectProtocol + IsMainThreadOnly {
    // Provided methods
    unsafe fn collectionView_numberOfItemsInSection(
        &self,
        collection_view: &NSCollectionView,
        section: NSInteger
    ) -> NSInteger
       where Self: Sized + Message { ... }
    unsafe fn collectionView_itemForRepresentedObjectAtIndexPath(
        &self,
        collection_view: &NSCollectionView,
        index_path: &NSIndexPath
    ) -> Id<NSCollectionViewItem>
       where Self: Sized + Message { ... }
    unsafe fn numberOfSectionsInCollectionView(
        &self,
        collection_view: &NSCollectionView
    ) -> NSInteger
       where Self: Sized + Message { ... }
    unsafe fn collectionView_viewForSupplementaryElementOfKind_atIndexPath(
        &self,
        collection_view: &NSCollectionView,
        kind: &NSCollectionViewSupplementaryElementKind,
        index_path: &NSIndexPath
    ) -> Id<NSView>
       where Self: Sized + Message { ... }
}
Available on crate feature NSCollectionView only.

Provided Methods§

source

unsafe fn collectionView_numberOfItemsInSection( &self, collection_view: &NSCollectionView, section: NSInteger ) -> NSInteger
where Self: Sized + Message,

Available on crate features NSResponder and NSView only.
source

unsafe fn collectionView_itemForRepresentedObjectAtIndexPath( &self, collection_view: &NSCollectionView, index_path: &NSIndexPath ) -> Id<NSCollectionViewItem>
where Self: Sized + Message,

Available on crate features NSResponder and NSView and NSViewController only.
source

unsafe fn numberOfSectionsInCollectionView( &self, collection_view: &NSCollectionView ) -> NSInteger
where Self: Sized + Message,

Available on crate features NSResponder and NSView only.
source

unsafe fn collectionView_viewForSupplementaryElementOfKind_atIndexPath( &self, collection_view: &NSCollectionView, kind: &NSCollectionViewSupplementaryElementKind, index_path: &NSIndexPath ) -> Id<NSView>
where Self: Sized + Message,

Available on crate features NSResponder and NSView only.

Trait Implementations§

source§

impl ProtocolType for dyn NSCollectionViewDataSource

source§

const NAME: &'static str = "NSCollectionViewDataSource"

The name of the Objective-C protocol that this type represents.
source§

fn protocol() -> Option<&'static AnyProtocol>

Get a reference to the Objective-C protocol object that this type represents. Read more
source§

impl<T> ImplementedBy<T> for dyn NSCollectionViewDataSource

Implementations on Foreign Types§

source§

impl<T> NSCollectionViewDataSource for ProtocolObject<T>

Implementors§