objc2_ml_compute/generated/
MLCComparisonLayer.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::*;
5
6use crate::*;
7
8extern_class!(
9    /// Compare layer.
10    ///
11    /// The layer is used to perform element-wise comparison of two tensor. Returns a
12    /// tensor with the shape equal to the largest shape of operands and filled
13    /// with Boolean values result[i] = op1[i] ? op2[i], where ? corresponds to the
14    /// given
15    /// `MLCComparisonOperation.`
16    ///
17    /// See also [Apple's documentation](https://developer.apple.com/documentation/mlcompute/mlccomparisonlayer?language=objc)
18    #[unsafe(super(MLCLayer, NSObject))]
19    #[derive(Debug, PartialEq, Eq, Hash)]
20    #[cfg(feature = "MLCLayer")]
21    #[deprecated]
22    pub struct MLCComparisonLayer;
23);
24
25#[cfg(feature = "MLCLayer")]
26extern_conformance!(
27    unsafe impl NSObjectProtocol for MLCComparisonLayer {}
28);
29
30#[cfg(feature = "MLCLayer")]
31impl MLCComparisonLayer {
32    extern_methods!(
33        #[cfg(feature = "MLCTypes")]
34        #[deprecated]
35        #[unsafe(method(operation))]
36        #[unsafe(method_family = none)]
37        pub unsafe fn operation(&self) -> MLCComparisonOperation;
38
39        #[cfg(feature = "MLCTypes")]
40        /// Create a comparison layer.
41        ///
42        /// Returns: A new compare layer.
43        #[deprecated]
44        #[unsafe(method(layerWithOperation:))]
45        #[unsafe(method_family = none)]
46        pub unsafe fn layerWithOperation(operation: MLCComparisonOperation) -> Retained<Self>;
47    );
48}
49
50/// Methods declared on superclass `MLCLayer`.
51#[cfg(feature = "MLCLayer")]
52impl MLCComparisonLayer {
53    extern_methods!(
54        #[deprecated]
55        #[unsafe(method(new))]
56        #[unsafe(method_family = new)]
57        pub unsafe fn new() -> Retained<Self>;
58
59        #[deprecated]
60        #[unsafe(method(init))]
61        #[unsafe(method_family = init)]
62        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
63    );
64}