objc2_ml_compute/generated/
MLCMultiheadAttentionDescriptor.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 #[unsafe(super(NSObject))]
15 #[derive(Debug, PartialEq, Eq, Hash)]
16 #[deprecated]
17 pub struct MLCMultiheadAttentionDescriptor;
18);
19
20extern_conformance!(
21 unsafe impl NSCopying for MLCMultiheadAttentionDescriptor {}
22);
23
24unsafe impl CopyingHelper for MLCMultiheadAttentionDescriptor {
25 type Result = Self;
26}
27
28extern_conformance!(
29 unsafe impl NSObjectProtocol for MLCMultiheadAttentionDescriptor {}
30);
31
32impl MLCMultiheadAttentionDescriptor {
33 extern_methods!(
34 #[deprecated]
35 #[unsafe(method(new))]
36 #[unsafe(method_family = new)]
37 pub unsafe fn new() -> Retained<Self>;
38
39 #[deprecated]
40 #[unsafe(method(init))]
41 #[unsafe(method_family = init)]
42 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
43
44 #[deprecated]
46 #[unsafe(method(modelDimension))]
47 #[unsafe(method_family = none)]
48 pub unsafe fn modelDimension(&self) -> NSUInteger;
49
50 #[deprecated]
52 #[unsafe(method(keyDimension))]
53 #[unsafe(method_family = none)]
54 pub unsafe fn keyDimension(&self) -> NSUInteger;
55
56 #[deprecated]
58 #[unsafe(method(valueDimension))]
59 #[unsafe(method_family = none)]
60 pub unsafe fn valueDimension(&self) -> NSUInteger;
61
62 #[deprecated]
64 #[unsafe(method(headCount))]
65 #[unsafe(method_family = none)]
66 pub unsafe fn headCount(&self) -> NSUInteger;
67
68 #[deprecated]
70 #[unsafe(method(dropout))]
71 #[unsafe(method_family = none)]
72 pub unsafe fn dropout(&self) -> c_float;
73
74 #[deprecated]
76 #[unsafe(method(hasBiases))]
77 #[unsafe(method_family = none)]
78 pub unsafe fn hasBiases(&self) -> bool;
79
80 #[deprecated]
82 #[unsafe(method(hasAttentionBiases))]
83 #[unsafe(method_family = none)]
84 pub unsafe fn hasAttentionBiases(&self) -> bool;
85
86 #[deprecated]
88 #[unsafe(method(addsZeroAttention))]
89 #[unsafe(method_family = none)]
90 pub unsafe fn addsZeroAttention(&self) -> bool;
91
92 #[deprecated]
112 #[unsafe(method(descriptorWithModelDimension:keyDimension:valueDimension:headCount:dropout:hasBiases:hasAttentionBiases:addsZeroAttention:))]
113 #[unsafe(method_family = none)]
114 pub unsafe fn descriptorWithModelDimension_keyDimension_valueDimension_headCount_dropout_hasBiases_hasAttentionBiases_addsZeroAttention(
115 model_dimension: NSUInteger,
116 key_dimension: NSUInteger,
117 value_dimension: NSUInteger,
118 head_count: NSUInteger,
119 dropout: c_float,
120 has_biases: bool,
121 has_attention_biases: bool,
122 adds_zero_attention: bool,
123 ) -> Option<Retained<Self>>;
124
125 #[deprecated]
133 #[unsafe(method(descriptorWithModelDimension:headCount:))]
134 #[unsafe(method_family = none)]
135 pub unsafe fn descriptorWithModelDimension_headCount(
136 model_dimension: NSUInteger,
137 head_count: NSUInteger,
138 ) -> Retained<Self>;
139 );
140}