objc2_web_kit/generated/
DOMHTMLSelectElement.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 #[unsafe(super(
13 DOMHTMLElement,
14 DOMElement,
15 DOMNode,
16 DOMObject,
17 WebScriptObject,
18 NSObject
19 ))]
20 #[derive(Debug, PartialEq, Eq, Hash)]
21 #[cfg(all(
22 feature = "DOMElement",
23 feature = "DOMHTMLElement",
24 feature = "DOMNode",
25 feature = "DOMObject",
26 feature = "WebScriptObject"
27 ))]
28 #[deprecated]
29 pub struct DOMHTMLSelectElement;
30);
31
32#[cfg(all(
33 feature = "DOMElement",
34 feature = "DOMEventTarget",
35 feature = "DOMHTMLElement",
36 feature = "DOMNode",
37 feature = "DOMObject",
38 feature = "WebScriptObject"
39))]
40unsafe impl DOMEventTarget for DOMHTMLSelectElement {}
41
42#[cfg(all(
43 feature = "DOMElement",
44 feature = "DOMHTMLElement",
45 feature = "DOMNode",
46 feature = "DOMObject",
47 feature = "WebScriptObject"
48))]
49unsafe impl NSCopying for DOMHTMLSelectElement {}
50
51#[cfg(all(
52 feature = "DOMElement",
53 feature = "DOMHTMLElement",
54 feature = "DOMNode",
55 feature = "DOMObject",
56 feature = "WebScriptObject"
57))]
58unsafe impl CopyingHelper for DOMHTMLSelectElement {
59 type Result = Self;
60}
61
62#[cfg(all(
63 feature = "DOMElement",
64 feature = "DOMHTMLElement",
65 feature = "DOMNode",
66 feature = "DOMObject",
67 feature = "WebScriptObject"
68))]
69unsafe impl NSObjectProtocol for DOMHTMLSelectElement {}
70
71#[cfg(all(
72 feature = "DOMElement",
73 feature = "DOMHTMLElement",
74 feature = "DOMNode",
75 feature = "DOMObject",
76 feature = "WebScriptObject"
77))]
78impl DOMHTMLSelectElement {
79 extern_methods!(
80 #[unsafe(method(autofocus))]
81 #[unsafe(method_family = none)]
82 pub unsafe fn autofocus(&self) -> bool;
83
84 #[unsafe(method(setAutofocus:))]
86 #[unsafe(method_family = none)]
87 pub unsafe fn setAutofocus(&self, autofocus: bool);
88
89 #[deprecated]
90 #[unsafe(method(disabled))]
91 #[unsafe(method_family = none)]
92 pub unsafe fn disabled(&self) -> bool;
93
94 #[deprecated]
96 #[unsafe(method(setDisabled:))]
97 #[unsafe(method_family = none)]
98 pub unsafe fn setDisabled(&self, disabled: bool);
99
100 #[cfg(feature = "DOMHTMLFormElement")]
101 #[deprecated]
102 #[unsafe(method(form))]
103 #[unsafe(method_family = none)]
104 pub unsafe fn form(&self) -> Option<Retained<DOMHTMLFormElement>>;
105
106 #[deprecated]
107 #[unsafe(method(multiple))]
108 #[unsafe(method_family = none)]
109 pub unsafe fn multiple(&self) -> bool;
110
111 #[deprecated]
113 #[unsafe(method(setMultiple:))]
114 #[unsafe(method_family = none)]
115 pub unsafe fn setMultiple(&self, multiple: bool);
116
117 #[deprecated]
118 #[unsafe(method(name))]
119 #[unsafe(method_family = none)]
120 pub unsafe fn name(&self) -> Retained<NSString>;
121
122 #[deprecated]
124 #[unsafe(method(setName:))]
125 #[unsafe(method_family = none)]
126 pub unsafe fn setName(&self, name: Option<&NSString>);
127
128 #[deprecated]
129 #[unsafe(method(size))]
130 #[unsafe(method_family = none)]
131 pub unsafe fn size(&self) -> c_int;
132
133 #[deprecated]
135 #[unsafe(method(setSize:))]
136 #[unsafe(method_family = none)]
137 pub unsafe fn setSize(&self, size: c_int);
138
139 #[deprecated]
140 #[unsafe(method(type))]
141 #[unsafe(method_family = none)]
142 pub unsafe fn r#type(&self) -> Retained<NSString>;
143
144 #[cfg(feature = "DOMHTMLOptionsCollection")]
145 #[deprecated]
146 #[unsafe(method(options))]
147 #[unsafe(method_family = none)]
148 pub unsafe fn options(&self) -> Option<Retained<DOMHTMLOptionsCollection>>;
149
150 #[deprecated]
151 #[unsafe(method(length))]
152 #[unsafe(method_family = none)]
153 pub unsafe fn length(&self) -> c_int;
154
155 #[deprecated]
156 #[unsafe(method(selectedIndex))]
157 #[unsafe(method_family = none)]
158 pub unsafe fn selectedIndex(&self) -> c_int;
159
160 #[deprecated]
162 #[unsafe(method(setSelectedIndex:))]
163 #[unsafe(method_family = none)]
164 pub unsafe fn setSelectedIndex(&self, selected_index: c_int);
165
166 #[deprecated]
167 #[unsafe(method(value))]
168 #[unsafe(method_family = none)]
169 pub unsafe fn value(&self) -> Retained<NSString>;
170
171 #[deprecated]
173 #[unsafe(method(setValue:))]
174 #[unsafe(method_family = none)]
175 pub unsafe fn setValue(&self, value: Option<&NSString>);
176
177 #[unsafe(method(willValidate))]
178 #[unsafe(method_family = none)]
179 pub unsafe fn willValidate(&self) -> bool;
180
181 #[unsafe(method(item:))]
182 #[unsafe(method_family = none)]
183 pub unsafe fn item(&self, index: c_uint) -> Option<Retained<DOMNode>>;
184
185 #[unsafe(method(namedItem:))]
186 #[unsafe(method_family = none)]
187 pub unsafe fn namedItem(&self, name: Option<&NSString>) -> Option<Retained<DOMNode>>;
188
189 #[unsafe(method(add:before:))]
190 #[unsafe(method_family = none)]
191 pub unsafe fn add_before(
192 &self,
193 element: Option<&DOMHTMLElement>,
194 before: Option<&DOMHTMLElement>,
195 );
196
197 #[deprecated]
198 #[unsafe(method(remove:))]
199 #[unsafe(method_family = none)]
200 pub unsafe fn remove(&self, index: c_int);
201 );
202}
203
204#[cfg(all(
206 feature = "DOMElement",
207 feature = "DOMHTMLElement",
208 feature = "DOMNode",
209 feature = "DOMObject",
210 feature = "WebScriptObject"
211))]
212impl DOMHTMLSelectElement {
213 extern_methods!(
214 #[deprecated]
215 #[unsafe(method(init))]
216 #[unsafe(method_family = init)]
217 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
218 );
219}
220
221#[cfg(all(
223 feature = "DOMElement",
224 feature = "DOMHTMLElement",
225 feature = "DOMNode",
226 feature = "DOMObject",
227 feature = "WebScriptObject"
228))]
229impl DOMHTMLSelectElement {
230 extern_methods!(
231 #[unsafe(method(new))]
232 #[unsafe(method_family = new)]
233 pub unsafe fn new() -> Retained<Self>;
234 );
235}
236
237#[cfg(all(
239 feature = "DOMElement",
240 feature = "DOMHTMLElement",
241 feature = "DOMNode",
242 feature = "DOMObject",
243 feature = "WebScriptObject"
244))]
245impl DOMHTMLSelectElement {
246 extern_methods!(
247 #[deprecated]
248 #[unsafe(method(add::))]
249 #[unsafe(method_family = none)]
250 pub unsafe fn add(&self, element: Option<&DOMHTMLElement>, before: Option<&DOMHTMLElement>);
251 );
252}