1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ffi::*;
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
extern_class!(
/// The MLCActivationDescriptor specifies a neuron descriptor.
///
/// See also [Apple's documentation](https://developer.apple.com/documentation/mlcompute/mlcactivationdescriptor?language=objc)
#[unsafe(super(NSObject))]
#[derive(Debug, PartialEq, Eq, Hash)]
#[deprecated]
pub struct MLCActivationDescriptor;
);
extern_conformance!(
unsafe impl NSCopying for MLCActivationDescriptor {}
);
unsafe impl CopyingHelper for MLCActivationDescriptor {
type Result = Self;
}
extern_conformance!(
unsafe impl NSObjectProtocol for MLCActivationDescriptor {}
);
impl MLCActivationDescriptor {
extern_methods!(
#[cfg(feature = "MLCTypes")]
/// The type of activation function
#[deprecated]
#[unsafe(method(activationType))]
#[unsafe(method_family = none)]
pub unsafe fn activationType(&self) -> MLCActivationType;
/// Parameter to the activation function
#[deprecated]
#[unsafe(method(a))]
#[unsafe(method_family = none)]
pub unsafe fn a(&self) -> c_float;
/// Parameter to the activation function
#[deprecated]
#[unsafe(method(b))]
#[unsafe(method_family = none)]
pub unsafe fn b(&self) -> c_float;
/// Parameter to the activation function
#[deprecated]
#[unsafe(method(c))]
#[unsafe(method_family = none)]
pub unsafe fn c(&self) -> c_float;
#[deprecated]
#[unsafe(method(new))]
#[unsafe(method_family = new)]
pub unsafe fn new() -> Retained<Self>;
#[deprecated]
#[unsafe(method(init))]
#[unsafe(method_family = init)]
pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
#[cfg(feature = "MLCTypes")]
/// Create a MLCActivationDescriptor object
///
/// Parameter `activationType`: A type of activation function.
///
/// Returns: A new neuron descriptor or nil if failure
#[deprecated]
#[unsafe(method(descriptorWithType:))]
#[unsafe(method_family = none)]
pub unsafe fn descriptorWithType(
activation_type: MLCActivationType,
) -> Option<Retained<Self>>;
#[cfg(feature = "MLCTypes")]
/// Create a MLCActivationDescriptor object
///
/// Parameter `activationType`: A type of activation function.
///
/// Parameter `a`: Parameter "a".
///
/// Returns: A new neuron descriptor or nil if failure
#[deprecated]
#[unsafe(method(descriptorWithType:a:))]
#[unsafe(method_family = none)]
pub unsafe fn descriptorWithType_a(
activation_type: MLCActivationType,
a: c_float,
) -> Option<Retained<Self>>;
#[cfg(feature = "MLCTypes")]
/// Create a MLCActivationDescriptor object
///
/// Parameter `activationType`: A type of activation function.
///
/// Parameter `a`: Parameter "a".
///
/// Parameter `b`: Parameter "b".
///
/// Returns: A new neuron descriptor or nil if failure
#[deprecated]
#[unsafe(method(descriptorWithType:a:b:))]
#[unsafe(method_family = none)]
pub unsafe fn descriptorWithType_a_b(
activation_type: MLCActivationType,
a: c_float,
b: c_float,
) -> Option<Retained<Self>>;
#[cfg(feature = "MLCTypes")]
/// Create a MLCActivationDescriptor object
///
/// Parameter `activationType`: A type of activation function.
///
/// Parameter `a`: Parameter "a".
///
/// Parameter `b`: Parameter "b".
///
/// Parameter `c`: Parameter "c".
///
/// Returns: A new neuron descriptor or nil if failure
#[deprecated]
#[unsafe(method(descriptorWithType:a:b:c:))]
#[unsafe(method_family = none)]
pub unsafe fn descriptorWithType_a_b_c(
activation_type: MLCActivationType,
a: c_float,
b: c_float,
c: c_float,
) -> Option<Retained<Self>>;
);
}