objc2_core_ml/generated/
MLModelStructureProgramBlock.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    /// A class representing a block in the Program.
11    ///
12    /// See also [Apple's documentation](https://developer.apple.com/documentation/coreml/mlmodelstructureprogramblock?language=objc)
13    #[unsafe(super(NSObject))]
14    #[derive(Debug, PartialEq, Eq, Hash)]
15    pub struct MLModelStructureProgramBlock;
16);
17
18unsafe impl Send for MLModelStructureProgramBlock {}
19
20unsafe impl Sync for MLModelStructureProgramBlock {}
21
22extern_conformance!(
23    unsafe impl NSObjectProtocol for MLModelStructureProgramBlock {}
24);
25
26impl MLModelStructureProgramBlock {
27    extern_methods!(
28        #[unsafe(method(init))]
29        #[unsafe(method_family = init)]
30        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
31
32        #[unsafe(method(new))]
33        #[unsafe(method_family = new)]
34        pub unsafe fn new() -> Retained<Self>;
35
36        #[cfg(feature = "MLModelStructureProgramNamedValueType")]
37        /// The named inputs to the block.
38        ///
39        /// This property is not atomic.
40        ///
41        /// # Safety
42        ///
43        /// This might not be thread-safe.
44        #[unsafe(method(inputs))]
45        #[unsafe(method_family = none)]
46        pub unsafe fn inputs(&self) -> Retained<NSArray<MLModelStructureProgramNamedValueType>>;
47
48        /// The output names.
49        ///
50        /// This property is not atomic.
51        ///
52        /// # Safety
53        ///
54        /// This might not be thread-safe.
55        #[unsafe(method(outputNames))]
56        #[unsafe(method_family = none)]
57        pub unsafe fn outputNames(&self) -> Retained<NSArray<NSString>>;
58
59        #[cfg(feature = "MLModelStructureProgramOperation")]
60        /// The list of topologically sorted operations in the block.
61        ///
62        /// This property is not atomic.
63        ///
64        /// # Safety
65        ///
66        /// This might not be thread-safe.
67        #[unsafe(method(operations))]
68        #[unsafe(method_family = none)]
69        pub unsafe fn operations(&self) -> Retained<NSArray<MLModelStructureProgramOperation>>;
70    );
71}