objc2_ui_kit/generated/
UILocalizedIndexedCollation.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10    /// [Apple's documentation](https://developer.apple.com/documentation/uikit/uilocalizedindexedcollation?language=objc)
11    #[unsafe(super(NSObject))]
12    #[thread_kind = MainThreadOnly]
13    #[derive(Debug, PartialEq, Eq, Hash)]
14    pub struct UILocalizedIndexedCollation;
15);
16
17extern_conformance!(
18    unsafe impl NSObjectProtocol for UILocalizedIndexedCollation {}
19);
20
21impl UILocalizedIndexedCollation {
22    extern_methods!(
23        #[unsafe(method(currentCollation))]
24        #[unsafe(method_family = none)]
25        pub unsafe fn currentCollation(mtm: MainThreadMarker) -> Retained<Self>;
26
27        #[unsafe(method(sectionTitles))]
28        #[unsafe(method_family = none)]
29        pub unsafe fn sectionTitles(&self) -> Retained<NSArray<NSString>>;
30
31        #[unsafe(method(sectionIndexTitles))]
32        #[unsafe(method_family = none)]
33        pub unsafe fn sectionIndexTitles(&self) -> Retained<NSArray<NSString>>;
34
35        #[unsafe(method(sectionForSectionIndexTitleAtIndex:))]
36        #[unsafe(method_family = none)]
37        pub unsafe fn sectionForSectionIndexTitleAtIndex(
38            &self,
39            index_title_index: NSInteger,
40        ) -> NSInteger;
41
42        #[unsafe(method(sectionForObject:collationStringSelector:))]
43        #[unsafe(method_family = none)]
44        pub unsafe fn sectionForObject_collationStringSelector(
45            &self,
46            object: &AnyObject,
47            selector: Sel,
48        ) -> NSInteger;
49
50        #[unsafe(method(sortedArrayFromArray:collationStringSelector:))]
51        #[unsafe(method_family = none)]
52        pub unsafe fn sortedArrayFromArray_collationStringSelector(
53            &self,
54            array: &NSArray,
55            selector: Sel,
56        ) -> Retained<NSArray>;
57    );
58}
59
60/// Methods declared on superclass `NSObject`.
61impl UILocalizedIndexedCollation {
62    extern_methods!(
63        #[unsafe(method(init))]
64        #[unsafe(method_family = init)]
65        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
66
67        #[unsafe(method(new))]
68        #[unsafe(method_family = new)]
69        pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
70    );
71}