objc2_open_directory/generated/ODNode.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 /// This class is used to work with OpenDirectory nodes.
11 ///
12 /// OpenDirectory uses nodes to represent different sources of directory information, via the local disk, LDAP, etc.
13 ///
14 /// See also [Apple's documentation](https://developer.apple.com/documentation/opendirectory/odnode?language=objc)
15 #[unsafe(super(NSObject))]
16 #[derive(Debug, PartialEq, Eq, Hash)]
17 pub struct ODNode;
18);
19
20extern_conformance!(
21 unsafe impl NSObjectProtocol for ODNode {}
22);
23
24impl ODNode {
25 extern_methods!(
26 #[cfg(all(
27 feature = "CFOpenDirectory",
28 feature = "CFOpenDirectoryConstants",
29 feature = "ODSession"
30 ))]
31 /// Create an autoreleased ODNode of the given type, optionally in a specific session.
32 ///
33 /// Autoreleased instance of an ODNode with a provided ODSession and ODNodeType. outError is
34 /// optional parameter, nil can be passed if error details are not needed.
35 ///
36 /// # Safety
37 ///
38 /// - `in_session` might not allow `None`.
39 /// - `out_error` might not allow `None`.
40 #[unsafe(method(nodeWithSession:type:error:))]
41 #[unsafe(method_family = none)]
42 pub unsafe fn nodeWithSession_type_error(
43 in_session: Option<&ODSession>,
44 in_type: ODNodeType,
45 out_error: Option<&mut Option<Retained<NSError>>>,
46 ) -> Option<Retained<Self>>;
47
48 #[cfg(feature = "ODSession")]
49 /// Create an autoreleased ODNode with the given name, optionally in a specific session.
50 ///
51 /// autoreleased instance of an ODNode with a provided ODSession and node name. outError is
52 /// optional parameter, nil can be passed if error details are not needed.
53 ///
54 /// # Safety
55 ///
56 /// - `in_session` might not allow `None`.
57 /// - `in_name` might not allow `None`.
58 /// - `out_error` might not allow `None`.
59 #[unsafe(method(nodeWithSession:name:error:))]
60 #[unsafe(method_family = none)]
61 pub unsafe fn nodeWithSession_name_error(
62 in_session: Option<&ODSession>,
63 in_name: Option<&NSString>,
64 out_error: Option<&mut Option<Retained<NSError>>>,
65 ) -> Option<Retained<Self>>;
66
67 #[cfg(all(
68 feature = "CFOpenDirectory",
69 feature = "CFOpenDirectoryConstants",
70 feature = "ODSession"
71 ))]
72 /// Initialize an ODNode instance of the given type, optionally in a specific session.
73 ///
74 /// initialize instance of an ODNode with a provided ODSession and ODNodeType. outError is
75 /// optional parameter, nil can be passed if error details are not needed.
76 ///
77 /// # Safety
78 ///
79 /// - `in_session` might not allow `None`.
80 /// - `out_error` might not allow `None`.
81 #[unsafe(method(initWithSession:type:error:))]
82 #[unsafe(method_family = init)]
83 pub unsafe fn initWithSession_type_error(
84 this: Allocated<Self>,
85 in_session: Option<&ODSession>,
86 in_type: ODNodeType,
87 out_error: Option<&mut Option<Retained<NSError>>>,
88 ) -> Option<Retained<Self>>;
89
90 #[cfg(feature = "ODSession")]
91 /// Initialize an ODNode instance with the given name, optionally in a specific session.
92 ///
93 /// initialize instance of an ODNode with a provided ODSession and node name. outError is optional
94 /// parameter, nil can be passed if error details are not needed.
95 ///
96 /// # Safety
97 ///
98 /// - `in_session` might not allow `None`.
99 /// - `in_name` might not allow `None`.
100 /// - `out_error` might not allow `None`.
101 #[unsafe(method(initWithSession:name:error:))]
102 #[unsafe(method_family = init)]
103 pub unsafe fn initWithSession_name_error(
104 this: Allocated<Self>,
105 in_session: Option<&ODSession>,
106 in_name: Option<&NSString>,
107 out_error: Option<&mut Option<Retained<NSError>>>,
108 ) -> Option<Retained<Self>>;
109
110 /// Returns NSArray of node names for this node, which may contain sub-nodes or search policy nodes
111 ///
112 /// Returns NSArray of node names for this node, which may contain sub-nodes or search policy nodes.
113 /// Commonly used with Search policy nodes. outError is optional parameter, nil can be passed if error
114 /// details are not needed.
115 ///
116 /// # Safety
117 ///
118 /// `out_error` might not allow `None`.
119 #[unsafe(method(subnodeNamesAndReturnError:))]
120 #[unsafe(method_family = none)]
121 pub unsafe fn subnodeNamesAndReturnError(
122 &self,
123 out_error: Option<&mut Option<Retained<NSError>>>,
124 ) -> Option<Retained<NSArray>>;
125
126 /// Will return NSArray of names of subnodes that are not currently reachable.
127 ///
128 /// Will return NSArray of names of subnodes that are not currently reachable. Commonly used with Search policy
129 /// nodes to determine if any nodes are currently unreachable, but may also return other subnodes if the
130 /// OpenDirectory plugin supports. outError is optional parameter, nil can be passed if error details are not needed.
131 ///
132 /// # Safety
133 ///
134 /// `out_error` might not allow `None`.
135 #[unsafe(method(unreachableSubnodeNamesAndReturnError:))]
136 #[unsafe(method_family = none)]
137 pub unsafe fn unreachableSubnodeNamesAndReturnError(
138 &self,
139 out_error: Option<&mut Option<Retained<NSError>>>,
140 ) -> Option<Retained<NSArray>>;
141
142 /// The node name.
143 ///
144 /// The node name, corresponding to its path in OpenDirectory.
145 #[unsafe(method(nodeName))]
146 #[unsafe(method_family = none)]
147 pub unsafe fn nodeName(&self) -> Retained<NSString>;
148
149 /// Returns a dictionary of information about the instance of ODNode
150 ///
151 /// Returns a dictionary of information about the instance of ODNode. Details such as Trust information
152 /// (kODAttributeTypeTrustInformation) or other Node details can be retrieved. outError is optional parameter,
153 /// nil can be passed if error details are not needed.
154 ///
155 /// # Safety
156 ///
157 /// - `in_keys` generic should be of the correct type.
158 /// - `in_keys` might not allow `None`.
159 /// - `out_error` might not allow `None`.
160 #[unsafe(method(nodeDetailsForKeys:error:))]
161 #[unsafe(method_family = none)]
162 pub unsafe fn nodeDetailsForKeys_error(
163 &self,
164 in_keys: Option<&NSArray>,
165 out_error: Option<&mut Option<Retained<NSError>>>,
166 ) -> Option<Retained<NSDictionary>>;
167
168 /// Returns a NSArray of the record types supported by this node.
169 ///
170 /// Returns a NSArray of the record types supported by this node. If node does not support the check
171 /// then all possible types will be returned. outError is optional parameter, nil can be passed if error details
172 /// are not needed.
173 ///
174 /// # Safety
175 ///
176 /// `out_error` might not allow `None`.
177 #[unsafe(method(supportedRecordTypesAndReturnError:))]
178 #[unsafe(method_family = none)]
179 pub unsafe fn supportedRecordTypesAndReturnError(
180 &self,
181 out_error: Option<&mut Option<Retained<NSError>>>,
182 ) -> Option<Retained<NSArray>>;
183
184 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
185 /// Will return a list of attribute types supported for that attribute if possible
186 ///
187 /// Will return a list of attribute types supported for that attribute if possible. If no specific
188 /// types are available, then all possible values will be returned instead. outError is optional parameter,
189 /// nil can be passed if error details are not needed.
190 ///
191 /// # Safety
192 ///
193 /// - `in_record_type` might not allow `None`.
194 /// - `out_error` might not allow `None`.
195 #[unsafe(method(supportedAttributesForRecordType:error:))]
196 #[unsafe(method_family = none)]
197 pub unsafe fn supportedAttributesForRecordType_error(
198 &self,
199 in_record_type: Option<&ODRecordType>,
200 out_error: Option<&mut Option<Retained<NSError>>>,
201 ) -> Option<Retained<NSArray>>;
202
203 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
204 /// Sets the credentials for interaction with the ODNode
205 ///
206 /// Sets the credentials for interaction with the ODNode. Record references, etc. will use these credentials
207 /// to query or change data. Setting the credentials on a node referenced by other OD object types will
208 /// change the credentials for all for all references. outError is optional parameter, nil can be passed if error
209 /// details are not needed.
210 ///
211 /// # Safety
212 ///
213 /// - `in_record_type` might not allow `None`.
214 /// - `in_record_name` might not allow `None`.
215 /// - `in_password` might not allow `None`.
216 /// - `out_error` might not allow `None`.
217 #[unsafe(method(setCredentialsWithRecordType:recordName:password:error:))]
218 #[unsafe(method_family = none)]
219 pub unsafe fn setCredentialsWithRecordType_recordName_password_error(
220 &self,
221 in_record_type: Option<&ODRecordType>,
222 in_record_name: Option<&NSString>,
223 in_password: Option<&NSString>,
224 out_error: Option<&mut Option<Retained<NSError>>>,
225 ) -> bool;
226
227 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
228 /// Allows use of other OpenDirectory types of authentications to set the credentials for an ODNode
229 ///
230 /// Allows the caller to use other types of authentications that are available in OpenDirectory, that may
231 /// require response-request loops, etc. Not all OD plugins will support this call, look for
232 /// kODErrorCredentialsMethodNotSupported in outError. outError is optional parameter, nil can be passed if
233 /// error details is not needed.
234 ///
235 /// # Safety
236 ///
237 /// - `in_record_type` might not allow `None`.
238 /// - `in_type` might not allow `None`.
239 /// - `in_items` generic should be of the correct type.
240 /// - `in_items` might not allow `None`.
241 /// - `out_items` generic should be of the correct type.
242 /// - `out_items` might not allow `None`.
243 /// - `out_context` should be of the correct type.
244 /// - `out_context` might not allow `None`.
245 /// - `out_error` might not allow `None`.
246 #[unsafe(method(setCredentialsWithRecordType:authenticationType:authenticationItems:continueItems:context:error:))]
247 #[unsafe(method_family = none)]
248 pub unsafe fn setCredentialsWithRecordType_authenticationType_authenticationItems_continueItems_context_error(
249 &self,
250 in_record_type: Option<&ODRecordType>,
251 in_type: Option<&ODAuthenticationType>,
252 in_items: Option<&NSArray>,
253 out_items: Option<&mut Option<Retained<NSArray>>>,
254 out_context: Option<&mut Option<Retained<AnyObject>>>,
255 out_error: Option<&mut Option<Retained<NSError>>>,
256 ) -> bool;
257
258 /// Unsupported method.
259 ///
260 /// Unsupported method.
261 ///
262 /// # Safety
263 ///
264 /// - `in_cache_name` might not allow `None`.
265 /// - `out_error` might not allow `None`.
266 #[deprecated]
267 #[unsafe(method(setCredentialsUsingKerberosCache:error:))]
268 #[unsafe(method_family = none)]
269 pub unsafe fn setCredentialsUsingKerberosCache_error(
270 &self,
271 in_cache_name: Option<&NSString>,
272 out_error: Option<&mut Option<Retained<NSError>>>,
273 ) -> bool;
274
275 #[cfg(all(
276 feature = "CFOpenDirectory",
277 feature = "CFOpenDirectoryConstants",
278 feature = "ODRecord"
279 ))]
280 /// Creates a record in this node, using the given name and attributes.
281 ///
282 /// Takes all the provided attributes and type to create an entire record. The function will assign a
283 /// UUID to the record automatically. This UUID can be overwritten by the client by passing with the
284 /// other attributes. inAttributes is optional, nil can be passed if no other attributes are to be set.
285 ///
286 /// # Safety
287 ///
288 /// - `in_record_type` might not allow `None`.
289 /// - `in_record_name` might not allow `None`.
290 /// - `in_attributes` generic should be of the correct type.
291 /// - `in_attributes` might not allow `None`.
292 /// - `out_error` might not allow `None`.
293 #[unsafe(method(createRecordWithRecordType:name:attributes:error:))]
294 #[unsafe(method_family = none)]
295 pub unsafe fn createRecordWithRecordType_name_attributes_error(
296 &self,
297 in_record_type: Option<&ODRecordType>,
298 in_record_name: Option<&NSString>,
299 in_attributes: Option<&NSDictionary>,
300 out_error: Option<&mut Option<Retained<NSError>>>,
301 ) -> Option<Retained<ODRecord>>;
302
303 #[cfg(all(
304 feature = "CFOpenDirectory",
305 feature = "CFOpenDirectoryConstants",
306 feature = "ODRecord"
307 ))]
308 /// Returns an ODRecord object that references the requested type and name
309 ///
310 /// Returns an ODRecord object that references the requested type and name. The record will have cached the
311 /// attributes requested. Further attributes can be requested via ODRecord APIs. For performance it is best
312 /// to ask for as many attributes that are needed as possible up front.
313 ///
314 /// # Safety
315 ///
316 /// - `in_record_type` might not allow `None`.
317 /// - `in_record_name` might not allow `None`.
318 /// - `in_attributes` should be of the correct type.
319 /// - `in_attributes` might not allow `None`.
320 /// - `out_error` might not allow `None`.
321 #[unsafe(method(recordWithRecordType:name:attributes:error:))]
322 #[unsafe(method_family = none)]
323 pub unsafe fn recordWithRecordType_name_attributes_error(
324 &self,
325 in_record_type: Option<&ODRecordType>,
326 in_record_name: Option<&NSString>,
327 in_attributes: Option<&AnyObject>,
328 out_error: Option<&mut Option<Retained<NSError>>>,
329 ) -> Option<Retained<ODRecord>>;
330
331 /// Sends a custom code to the node; input and output data formats are specific to the call.
332 ///
333 /// Sends a custom code to the node; input and output data formats are specific to the call. outError is
334 /// optional parameter, nil can be passed if error details are not needed.
335 ///
336 /// # Safety
337 ///
338 /// - `in_send_data` might not allow `None`.
339 /// - `out_error` might not allow `None`.
340 #[unsafe(method(customCall:sendData:error:))]
341 #[unsafe(method_family = none)]
342 pub unsafe fn customCall_sendData_error(
343 &self,
344 in_custom_code: NSInteger,
345 in_send_data: Option<&NSData>,
346 out_error: Option<&mut Option<Retained<NSError>>>,
347 ) -> Option<Retained<NSData>>;
348
349 /// Sends a custom function call to the node; data is a type specific to the call.
350 ///
351 /// Sends a custom function call to the node; data is a type specific to the call. 'error' is an
352 /// optional parameter therefore nil can be passed if error details are not needed. Return type is
353 /// defined by the custom function requested.
354 ///
355 /// # Safety
356 ///
357 /// - `function` might not allow `None`.
358 /// - `payload` should be of the correct type.
359 /// - `payload` might not allow `None`.
360 /// - `error` might not allow `None`.
361 #[unsafe(method(customFunction:payload:error:))]
362 #[unsafe(method_family = none)]
363 pub unsafe fn customFunction_payload_error(
364 &self,
365 function: Option<&NSString>,
366 payload: Option<&AnyObject>,
367 error: Option<&mut Option<Retained<NSError>>>,
368 ) -> Option<Retained<AnyObject>>;
369
370 #[cfg(feature = "ODConfiguration")]
371 /// Returns an ODConfiguration object for the node.
372 ///
373 ///
374 /// Returns an ODConfiguration object for the node.
375 #[unsafe(method(configuration))]
376 #[unsafe(method_family = none)]
377 pub unsafe fn configuration(&self) -> Option<Retained<ODConfiguration>>;
378
379 /// This will copy any policies configured for the node.
380 ///
381 /// This will copy any policies configured for the node.
382 ///
383 /// # Safety
384 ///
385 /// `error` might not allow `None`.
386 #[deprecated = "use accountPoliciesAndReturnError:"]
387 #[unsafe(method(policiesAndReturnError:))]
388 #[unsafe(method_family = none)]
389 pub unsafe fn policiesAndReturnError(
390 &self,
391 error: Option<&mut Option<Retained<NSError>>>,
392 ) -> Option<Retained<NSDictionary>>;
393
394 /// This will return a dictionary of supported policies.
395 ///
396 /// This will return a dictionary of supported policies, if appropriate, the value will be the maximum value allowed
397 /// for the policy in question. For example, if password history is available, it will state how much history is
398 /// supported.
399 ///
400 /// # Safety
401 ///
402 /// `error` might not allow `None`.
403 #[deprecated]
404 #[unsafe(method(supportedPoliciesAndReturnError:))]
405 #[unsafe(method_family = none)]
406 pub unsafe fn supportedPoliciesAndReturnError(
407 &self,
408 error: Option<&mut Option<Retained<NSError>>>,
409 ) -> Option<Retained<NSDictionary>>;
410
411 /// This will set the policy for the node.
412 ///
413 /// This will set the policy for the node. Policies are evaluated in combination with record-level policies.
414 ///
415 /// # Safety
416 ///
417 /// - `policies` generic should be of the correct type.
418 /// - `policies` might not allow `None`.
419 /// - `error` might not allow `None`.
420 #[deprecated = "use setAccountPolicies:error:"]
421 #[unsafe(method(setPolicies:error:))]
422 #[unsafe(method_family = none)]
423 pub unsafe fn setPolicies_error(
424 &self,
425 policies: Option<&NSDictionary>,
426 error: Option<&mut Option<Retained<NSError>>>,
427 ) -> bool;
428
429 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
430 /// This will set a specific policy setting for the node.
431 ///
432 /// This will set a specific policy setting for the node.
433 ///
434 /// # Safety
435 ///
436 /// - `policy` might not allow `None`.
437 /// - `value` should be of the correct type.
438 /// - `value` might not allow `None`.
439 /// - `error` might not allow `None`.
440 #[deprecated = "use addAccountPolicy:toCategory:error:"]
441 #[unsafe(method(setPolicy:value:error:))]
442 #[unsafe(method_family = none)]
443 pub unsafe fn setPolicy_value_error(
444 &self,
445 policy: Option<&ODPolicyType>,
446 value: Option<&AnyObject>,
447 error: Option<&mut Option<Retained<NSError>>>,
448 ) -> bool;
449
450 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
451 /// This will remove a specific policy setting from the node.
452 ///
453 /// This will remove a specific policy setting from the node.
454 ///
455 /// # Safety
456 ///
457 /// - `policy` might not allow `None`.
458 /// - `error` might not allow `None`.
459 #[deprecated = "use removeAccountPolicy:fromCategory:error:"]
460 #[unsafe(method(removePolicy:error:))]
461 #[unsafe(method_family = none)]
462 pub unsafe fn removePolicy_error(
463 &self,
464 policy: Option<&ODPolicyType>,
465 error: Option<&mut Option<Retained<NSError>>>,
466 ) -> bool;
467
468 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
469 /// This will add an account policy to the node for the specified category.
470 ///
471 /// This will add an account policy to the node for the specified category.
472 /// The specified policy will be applied to all users in the
473 /// specified node when policies are evaluated.
474 ///
475 /// Parameter `policy`: a dictionary containing the specific policy to be added.
476 /// The dictionary may contain the following keys:
477 /// kODPolicyKeyIdentifier a required key identifying the policy.
478 /// kODPolicyKeyParameters an optional key containing a dictionary of
479 /// parameters that can be used for informational purposes or in
480 /// the policy format string.
481 /// kODPolicyKeyContent a required key specifying the policy,
482 /// from which a predicate will be created for evaluating
483 /// the policy.
484 ///
485 /// Parameter `category`: a valid ODPolicyCategoryType to which the specified policy will be added.
486 ///
487 /// Parameter `error`: an optional NSError reference for error details.
488 ///
489 /// Returns: a BOOL which signifies if the policy addition succeeded, otherwise error is set.
490 ///
491 /// # Safety
492 ///
493 /// - `policy` generic should be of the correct type.
494 /// - `policy` might not allow `None`.
495 /// - `category` might not allow `None`.
496 /// - `error` might not allow `None`.
497 #[unsafe(method(addAccountPolicy:toCategory:error:))]
498 #[unsafe(method_family = none)]
499 pub unsafe fn addAccountPolicy_toCategory_error(
500 &self,
501 policy: Option<&NSDictionary>,
502 category: Option<&ODPolicyCategoryType>,
503 error: Option<&mut Option<Retained<NSError>>>,
504 ) -> bool;
505
506 #[cfg(all(feature = "CFOpenDirectory", feature = "CFOpenDirectoryConstants"))]
507 /// This will remove an account policy from the node for the specified category.
508 ///
509 /// This will remove an account policy from the node for the specified category.
510 ///
511 /// Parameter `policy`: a dictionary containing the specific policy to be
512 /// removed, with the same format as described in addAccountPolicy.
513 ///
514 /// Parameter `category`: a valid ODPolicyCategoryType from which the specified policy will be removed.
515 ///
516 /// Parameter `error`: an optional NSError reference for error details.
517 ///
518 /// Returns: a BOOL which signifies if the policy removal succeeded, otherwise error is set.
519 ///
520 /// # Safety
521 ///
522 /// - `policy` generic should be of the correct type.
523 /// - `policy` might not allow `None`.
524 /// - `category` might not allow `None`.
525 /// - `error` might not allow `None`.
526 #[unsafe(method(removeAccountPolicy:fromCategory:error:))]
527 #[unsafe(method_family = none)]
528 pub unsafe fn removeAccountPolicy_fromCategory_error(
529 &self,
530 policy: Option<&NSDictionary>,
531 category: Option<&ODPolicyCategoryType>,
532 error: Option<&mut Option<Retained<NSError>>>,
533 ) -> bool;
534
535 /// This will set the policies for the node.
536 ///
537 /// This will set the policies for the node, replacing any existing
538 /// policies. All of the policies in the set will be applied to all
539 /// users in the specified node when policies are evaluated.
540 ///
541 /// Parameter `policies`: a dictionary containing all of the policies to be set
542 /// for the node. The dictionary may contain the following keys:
543 /// kODPolicyCategoryAuthentication an optional key with a value
544 /// of an array of policy dictionaries that specify when
545 /// authentications should be allowed.
546 /// kODPolicyCategoryPasswordContent an optional key with a
547 /// value of an array of policy dictionaries the specify the
548 /// required content of passwords.
549 /// kODPolicyCategoryPasswordChange an optional key with a value
550 /// of an array of policy dictionaries that specify when
551 /// passwords are required to be changed.
552 ///
553 /// Parameter `error`: an optional NSError reference for error details.
554 ///
555 /// Returns: a BOOL which signifies if the policy set succeeded, otherwise error is set.
556 ///
557 /// # Safety
558 ///
559 /// - `policies` generic should be of the correct type.
560 /// - `policies` might not allow `None`.
561 /// - `error` might not allow `None`.
562 #[unsafe(method(setAccountPolicies:error:))]
563 #[unsafe(method_family = none)]
564 pub unsafe fn setAccountPolicies_error(
565 &self,
566 policies: Option<&NSDictionary>,
567 error: Option<&mut Option<Retained<NSError>>>,
568 ) -> bool;
569
570 /// Returns a dictionary containing any policies configured for the node.
571 ///
572 /// Returns a dictionary containing any policies configured for the node.
573 ///
574 /// Parameter `error`: an optional NSError reference for error details.
575 ///
576 /// Returns: an NSDictionary containing all currently set policies. The
577 /// format of the dictionary is the same as described in
578 /// setAccountPolicies.
579 ///
580 /// # Safety
581 ///
582 /// `error` might not allow `None`.
583 #[unsafe(method(accountPoliciesAndReturnError:))]
584 #[unsafe(method_family = none)]
585 pub unsafe fn accountPoliciesAndReturnError(
586 &self,
587 error: Option<&mut Option<Retained<NSError>>>,
588 ) -> Option<Retained<NSDictionary>>;
589
590 /// Validates a password against the node's password content policies.
591 ///
592 /// Validates a password against the node's password content policies.
593 /// The node's password content policies will be evaluated to
594 /// determine if the password is acceptable. May be used prior to
595 /// creating the record.
596 ///
597 /// This check is only definitive at the time it was requested. The
598 /// policy or the environment could change before the password change
599 /// is actually requested. Errors from the password change request
600 /// should be consulted.
601 ///
602 ///
603 /// Parameter `password`: the password to be evaluated against the content policies.
604 ///
605 /// Parameter `recordName`: the name of the record.
606 ///
607 /// Parameter `error`: an optional NSError reference for error details.
608 ///
609 /// Returns: a bool which signifies if the password passes all content policies, otherwise error is set.
610 ///
611 /// # Safety
612 ///
613 /// - `password` might not allow `None`.
614 /// - `record_name` might not allow `None`.
615 /// - `error` might not allow `None`.
616 #[unsafe(method(passwordContentCheck:forRecordName:error:))]
617 #[unsafe(method_family = none)]
618 pub unsafe fn passwordContentCheck_forRecordName_error(
619 &self,
620 password: Option<&NSString>,
621 record_name: Option<&NSString>,
622 error: Option<&mut Option<Retained<NSError>>>,
623 ) -> bool;
624 );
625}
626
627/// Methods declared on superclass `NSObject`.
628impl ODNode {
629 extern_methods!(
630 #[unsafe(method(init))]
631 #[unsafe(method_family = init)]
632 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
633
634 #[unsafe(method(new))]
635 #[unsafe(method_family = new)]
636 pub unsafe fn new() -> Retained<Self>;
637 );
638}