objc2_core_ml/generated/
MLDictionaryConstraint.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    /// MLDictionaryConstraint
11    ///
12    /// Constraint describing expected NSDictionary properties
13    ///
14    /// See also [Apple's documentation](https://developer.apple.com/documentation/coreml/mldictionaryconstraint?language=objc)
15    #[unsafe(super(NSObject))]
16    #[derive(Debug, PartialEq, Eq, Hash)]
17    pub struct MLDictionaryConstraint;
18);
19
20extern_conformance!(
21    unsafe impl NSCoding for MLDictionaryConstraint {}
22);
23
24extern_conformance!(
25    unsafe impl NSObjectProtocol for MLDictionaryConstraint {}
26);
27
28extern_conformance!(
29    unsafe impl NSSecureCoding for MLDictionaryConstraint {}
30);
31
32impl MLDictionaryConstraint {
33    extern_methods!(
34        #[cfg(feature = "MLFeatureType")]
35        /// Required key type, described as MLFeatureType
36        #[unsafe(method(keyType))]
37        #[unsafe(method_family = none)]
38        pub unsafe fn keyType(&self) -> MLFeatureType;
39    );
40}
41
42/// Methods declared on superclass `NSObject`.
43impl MLDictionaryConstraint {
44    extern_methods!(
45        #[unsafe(method(init))]
46        #[unsafe(method_family = init)]
47        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
48
49        #[unsafe(method(new))]
50        #[unsafe(method_family = new)]
51        pub unsafe fn new() -> Retained<Self>;
52    );
53}