objc2_core_services/generated/OSServices/
WSMethodInvocation.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::cell::UnsafeCell;
4use core::ffi::*;
5use core::marker::{PhantomData, PhantomPinned};
6use core::ptr::NonNull;
7#[cfg(feature = "objc2")]
8use objc2::__framework_prelude::*;
9use objc2_core_foundation::*;
10
11use crate::*;
12
13extern "C" {
14    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsmethodinvocationresult?language=objc)
15    #[deprecated = "No longer supported"]
16    pub static kWSMethodInvocationResult: Option<&'static CFString>;
17}
18
19extern "C" {
20    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsfaultstring?language=objc)
21    #[deprecated = "No longer supported"]
22    pub static kWSFaultString: Option<&'static CFString>;
23}
24
25extern "C" {
26    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsfaultcode?language=objc)
27    #[deprecated = "No longer supported"]
28    pub static kWSFaultCode: Option<&'static CFString>;
29}
30
31extern "C" {
32    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsfaultextra?language=objc)
33    #[deprecated = "No longer supported"]
34    pub static kWSFaultExtra: Option<&'static CFString>;
35}
36
37extern "C" {
38    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsnetworkstreamfaultstring?language=objc)
39    #[deprecated = "No longer supported"]
40    pub static kWSNetworkStreamFaultString: Option<&'static CFString>;
41}
42
43extern "C" {
44    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsstreamerrormessage?language=objc)
45    #[deprecated = "No longer supported"]
46    pub static kWSStreamErrorMessage: Option<&'static CFString>;
47}
48
49extern "C" {
50    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsstreamerrordomain?language=objc)
51    #[deprecated = "No longer supported"]
52    pub static kWSStreamErrorDomain: Option<&'static CFString>;
53}
54
55extern "C" {
56    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsstreamerrorerror?language=objc)
57    #[deprecated = "No longer supported"]
58    pub static kWSStreamErrorError: Option<&'static CFString>;
59}
60
61extern "C" {
62    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwshttpmessage?language=objc)
63    #[deprecated = "No longer supported"]
64    pub static kWSHTTPMessage: Option<&'static CFString>;
65}
66
67extern "C" {
68    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwshttpresponsemessage?language=objc)
69    #[deprecated = "No longer supported"]
70    pub static kWSHTTPResponseMessage: Option<&'static CFString>;
71}
72
73extern "C" {
74    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwshttpextraheaders?language=objc)
75    #[deprecated = "No longer supported"]
76    pub static kWSHTTPExtraHeaders: Option<&'static CFString>;
77}
78
79extern "C" {
80    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwshttpversion?language=objc)
81    #[deprecated = "No longer supported"]
82    pub static kWSHTTPVersion: Option<&'static CFString>;
83}
84
85extern "C" {
86    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwshttpproxy?language=objc)
87    #[deprecated = "No longer supported"]
88    pub static kWSHTTPProxy: Option<&'static CFString>;
89}
90
91extern "C" {
92    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwshttpfollowsredirects?language=objc)
93    #[deprecated = "No longer supported"]
94    pub static kWSHTTPFollowsRedirects: Option<&'static CFString>;
95}
96
97extern "C" {
98    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsdebugoutgoingheaders?language=objc)
99    #[deprecated = "No longer supported"]
100    pub static kWSDebugOutgoingHeaders: Option<&'static CFString>;
101}
102
103extern "C" {
104    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsdebugoutgoingbody?language=objc)
105    #[deprecated = "No longer supported"]
106    pub static kWSDebugOutgoingBody: Option<&'static CFString>;
107}
108
109extern "C" {
110    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsdebugincomingheaders?language=objc)
111    #[deprecated = "No longer supported"]
112    pub static kWSDebugIncomingHeaders: Option<&'static CFString>;
113}
114
115extern "C" {
116    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsdebugincomingbody?language=objc)
117    #[deprecated = "No longer supported"]
118    pub static kWSDebugIncomingBody: Option<&'static CFString>;
119}
120
121extern "C" {
122    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwssoapbodyencodingstyle?language=objc)
123    #[deprecated = "No longer supported"]
124    pub static kWSSOAPBodyEncodingStyle: Option<&'static CFString>;
125}
126
127extern "C" {
128    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwssoapmethodnamespaceuri?language=objc)
129    #[deprecated = "No longer supported"]
130    pub static kWSSOAPMethodNamespaceURI: Option<&'static CFString>;
131}
132
133extern "C" {
134    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwssoapstyledoc?language=objc)
135    #[deprecated = "No longer supported"]
136    pub static kWSSOAPStyleDoc: Option<&'static CFString>;
137}
138
139extern "C" {
140    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwssoapstylerpc?language=objc)
141    #[deprecated = "No longer supported"]
142    pub static kWSSOAPStyleRPC: Option<&'static CFString>;
143}
144
145extern "C" {
146    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwssoapmessageheaders?language=objc)
147    #[deprecated = "No longer supported"]
148    pub static kWSSOAPMessageHeaders: Option<&'static CFString>;
149}
150
151extern "C" {
152    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsrecordparameterorder?language=objc)
153    #[deprecated = "No longer supported"]
154    pub static kWSRecordParameterOrder: Option<&'static CFString>;
155}
156
157extern "C" {
158    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsrecordnamespaceuri?language=objc)
159    #[deprecated = "No longer supported"]
160    pub static kWSRecordNamespaceURI: Option<&'static CFString>;
161}
162
163extern "C" {
164    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsrecordtype?language=objc)
165    #[deprecated = "No longer supported"]
166    pub static kWSRecordType: Option<&'static CFString>;
167}
168
169extern "C" {
170    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsmethodinvocationresultparametername?language=objc)
171    #[deprecated = "No longer supported"]
172    pub static kWSMethodInvocationResultParameterName: Option<&'static CFString>;
173}
174
175extern "C" {
176    /// [Apple's documentation](https://developer.apple.com/documentation/coreservices/kwsmethodinvocationtimeoutvalue?language=objc)
177    #[deprecated = "No longer supported"]
178    pub static kWSMethodInvocationTimeoutValue: Option<&'static CFString>;
179}
180
181/// [Apple's documentation](https://developer.apple.com/documentation/coreservices/wsmethodinvocation?language=objc)
182#[doc(alias = "WSMethodInvocationRef")]
183#[repr(C)]
184pub struct WSMethodInvocation {
185    inner: [u8; 0],
186    _p: UnsafeCell<PhantomData<(*const UnsafeCell<()>, PhantomPinned)>>,
187}
188
189cf_type!(
190    unsafe impl WSMethodInvocation {}
191);
192#[cfg(feature = "objc2")]
193cf_objc2_type!(
194    unsafe impl RefEncode<"OpaqueWSMethodInvocationRef"> for WSMethodInvocation {}
195);
196
197unsafe impl ConcreteType for WSMethodInvocation {
198    #[doc(alias = "WSMethodInvocationGetTypeID")]
199    #[inline]
200    fn type_id() -> CFTypeID {
201        extern "C-unwind" {
202            fn WSMethodInvocationGetTypeID() -> CFTypeID;
203        }
204        unsafe { WSMethodInvocationGetTypeID() }
205    }
206}
207
208impl WSMethodInvocation {
209    /// # Safety
210    ///
211    /// - `url` might not allow `None`.
212    /// - `method_name` might not allow `None`.
213    /// - `protocol` might not allow `None`.
214    #[doc(alias = "WSMethodInvocationCreate")]
215    #[deprecated = "No longer supported"]
216    #[inline]
217    pub unsafe fn new(
218        url: Option<&CFURL>,
219        method_name: Option<&CFString>,
220        protocol: Option<&CFString>,
221    ) -> Option<CFRetained<WSMethodInvocation>> {
222        extern "C-unwind" {
223            fn WSMethodInvocationCreate(
224                url: Option<&CFURL>,
225                method_name: Option<&CFString>,
226                protocol: Option<&CFString>,
227            ) -> Option<NonNull<WSMethodInvocation>>;
228        }
229        let ret = unsafe { WSMethodInvocationCreate(url, method_name, protocol) };
230        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
231    }
232
233    /// # Safety
234    ///
235    /// `contract` might not allow `None`.
236    #[doc(alias = "WSMethodInvocationCreateFromSerialization")]
237    #[deprecated = "No longer supported"]
238    #[inline]
239    pub unsafe fn from_serialization(
240        contract: Option<&CFData>,
241    ) -> Option<CFRetained<WSMethodInvocation>> {
242        extern "C-unwind" {
243            fn WSMethodInvocationCreateFromSerialization(
244                contract: Option<&CFData>,
245            ) -> Option<NonNull<WSMethodInvocation>>;
246        }
247        let ret = unsafe { WSMethodInvocationCreateFromSerialization(contract) };
248        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
249    }
250
251    #[doc(alias = "WSMethodInvocationCopySerialization")]
252    #[deprecated = "No longer supported"]
253    #[inline]
254    pub unsafe fn serialization(&self) -> Option<CFRetained<CFData>> {
255        extern "C-unwind" {
256            fn WSMethodInvocationCopySerialization(
257                invocation: &WSMethodInvocation,
258            ) -> Option<NonNull<CFData>>;
259        }
260        let ret = unsafe { WSMethodInvocationCopySerialization(self) };
261        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
262    }
263
264    /// # Safety
265    ///
266    /// - `parameters` generics must be of the correct type.
267    /// - `parameters` might not allow `None`.
268    /// - `parameter_order` generic must be of the correct type.
269    /// - `parameter_order` might not allow `None`.
270    #[doc(alias = "WSMethodInvocationSetParameters")]
271    #[deprecated = "No longer supported"]
272    #[inline]
273    pub unsafe fn set_parameters(
274        &self,
275        parameters: Option<&CFDictionary>,
276        parameter_order: Option<&CFArray>,
277    ) {
278        extern "C-unwind" {
279            fn WSMethodInvocationSetParameters(
280                invocation: &WSMethodInvocation,
281                parameters: Option<&CFDictionary>,
282                parameter_order: Option<&CFArray>,
283            );
284        }
285        unsafe { WSMethodInvocationSetParameters(self, parameters, parameter_order) }
286    }
287
288    /// # Safety
289    ///
290    /// `parameter_order` must be a valid pointer.
291    #[doc(alias = "WSMethodInvocationCopyParameters")]
292    #[deprecated = "No longer supported"]
293    #[inline]
294    pub unsafe fn parameters(
295        &self,
296        parameter_order: *mut *const CFArray,
297    ) -> Option<CFRetained<CFDictionary>> {
298        extern "C-unwind" {
299            fn WSMethodInvocationCopyParameters(
300                invocation: &WSMethodInvocation,
301                parameter_order: *mut *const CFArray,
302            ) -> Option<NonNull<CFDictionary>>;
303        }
304        let ret = unsafe { WSMethodInvocationCopyParameters(self, parameter_order) };
305        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
306    }
307
308    /// # Safety
309    ///
310    /// - `property_name` might not allow `None`.
311    /// - `property_value` should be of the correct type.
312    /// - `property_value` might not allow `None`.
313    #[doc(alias = "WSMethodInvocationSetProperty")]
314    #[deprecated = "No longer supported"]
315    #[inline]
316    pub unsafe fn set_property(
317        &self,
318        property_name: Option<&CFString>,
319        property_value: Option<&CFType>,
320    ) {
321        extern "C-unwind" {
322            fn WSMethodInvocationSetProperty(
323                invocation: &WSMethodInvocation,
324                property_name: Option<&CFString>,
325                property_value: Option<&CFType>,
326            );
327        }
328        unsafe { WSMethodInvocationSetProperty(self, property_name, property_value) }
329    }
330
331    /// # Safety
332    ///
333    /// `property_name` might not allow `None`.
334    #[doc(alias = "WSMethodInvocationCopyProperty")]
335    #[deprecated = "No longer supported"]
336    #[inline]
337    pub unsafe fn property(&self, property_name: Option<&CFString>) -> Option<CFRetained<CFType>> {
338        extern "C-unwind" {
339            fn WSMethodInvocationCopyProperty(
340                invocation: &WSMethodInvocation,
341                property_name: Option<&CFString>,
342            ) -> Option<NonNull<CFType>>;
343        }
344        let ret = unsafe { WSMethodInvocationCopyProperty(self, property_name) };
345        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
346    }
347
348    #[doc(alias = "WSMethodInvocationInvoke")]
349    #[deprecated = "No longer supported"]
350    #[inline]
351    pub unsafe fn invoke(&self) -> Option<CFRetained<CFDictionary>> {
352        extern "C-unwind" {
353            fn WSMethodInvocationInvoke(
354                invocation: &WSMethodInvocation,
355            ) -> Option<NonNull<CFDictionary>>;
356        }
357        let ret = unsafe { WSMethodInvocationInvoke(self) };
358        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
359    }
360}
361
362/// [Apple's documentation](https://developer.apple.com/documentation/coreservices/wsmethodinvocationcallbackprocptr?language=objc)
363#[deprecated = "No longer supported"]
364pub type WSMethodInvocationCallBackProcPtr =
365    Option<unsafe extern "C-unwind" fn(*mut WSMethodInvocation, *mut c_void, *const CFDictionary)>;
366
367impl WSMethodInvocation {
368    /// # Safety
369    ///
370    /// - `client_cb` must be implemented correctly.
371    /// - `context` must be a valid pointer.
372    #[doc(alias = "WSMethodInvocationSetCallBack")]
373    #[cfg(feature = "WSTypes")]
374    #[deprecated = "No longer supported"]
375    #[inline]
376    pub unsafe fn set_call_back(
377        &self,
378        client_cb: WSMethodInvocationCallBackProcPtr,
379        context: *mut WSClientContext,
380    ) {
381        extern "C-unwind" {
382            fn WSMethodInvocationSetCallBack(
383                invocation: &WSMethodInvocation,
384                client_cb: WSMethodInvocationCallBackProcPtr,
385                context: *mut WSClientContext,
386            );
387        }
388        unsafe { WSMethodInvocationSetCallBack(self, client_cb, context) }
389    }
390
391    /// # Safety
392    ///
393    /// - `run_loop` possibly has additional threading requirements.
394    /// - `run_loop` might not allow `None`.
395    /// - `run_loop_mode` might not allow `None`.
396    #[doc(alias = "WSMethodInvocationScheduleWithRunLoop")]
397    #[deprecated = "No longer supported"]
398    #[inline]
399    pub unsafe fn schedule_with_run_loop(
400        &self,
401        run_loop: Option<&CFRunLoop>,
402        run_loop_mode: Option<&CFString>,
403    ) {
404        extern "C-unwind" {
405            fn WSMethodInvocationScheduleWithRunLoop(
406                invocation: &WSMethodInvocation,
407                run_loop: Option<&CFRunLoop>,
408                run_loop_mode: Option<&CFString>,
409            );
410        }
411        unsafe { WSMethodInvocationScheduleWithRunLoop(self, run_loop, run_loop_mode) }
412    }
413
414    /// # Safety
415    ///
416    /// - `run_loop` possibly has additional threading requirements.
417    /// - `run_loop` might not allow `None`.
418    /// - `run_loop_mode` might not allow `None`.
419    #[doc(alias = "WSMethodInvocationUnscheduleFromRunLoop")]
420    #[deprecated = "No longer supported"]
421    #[inline]
422    pub unsafe fn unschedule_from_run_loop(
423        &self,
424        run_loop: Option<&CFRunLoop>,
425        run_loop_mode: Option<&CFString>,
426    ) {
427        extern "C-unwind" {
428            fn WSMethodInvocationUnscheduleFromRunLoop(
429                invocation: &WSMethodInvocation,
430                run_loop: Option<&CFRunLoop>,
431                run_loop_mode: Option<&CFString>,
432            );
433        }
434        unsafe { WSMethodInvocationUnscheduleFromRunLoop(self, run_loop, run_loop_mode) }
435    }
436}
437
438/// # Safety
439///
440/// - `method_result` generics must be of the correct type.
441/// - `method_result` might not allow `None`.
442#[deprecated = "No longer supported"]
443#[inline]
444pub unsafe extern "C-unwind" fn WSMethodResultIsFault(
445    method_result: Option<&CFDictionary>,
446) -> bool {
447    extern "C-unwind" {
448        fn WSMethodResultIsFault(method_result: Option<&CFDictionary>) -> Boolean;
449    }
450    let ret = unsafe { WSMethodResultIsFault(method_result) };
451    ret != 0
452}
453
454/// [Apple's documentation](https://developer.apple.com/documentation/coreservices/wsmethodinvocationserializationprocptr?language=objc)
455#[deprecated = "No longer supported"]
456pub type WSMethodInvocationSerializationProcPtr = Option<
457    unsafe extern "C-unwind" fn(
458        *mut WSMethodInvocation,
459        *const CFType,
460        *mut c_void,
461    ) -> *const CFString,
462>;
463
464impl WSMethodInvocation {
465    /// # Safety
466    ///
467    /// - `serialization_proc` must be implemented correctly.
468    /// - `context` must be a valid pointer.
469    #[doc(alias = "WSMethodInvocationAddSerializationOverride")]
470    #[cfg(feature = "WSTypes")]
471    #[deprecated = "No longer supported"]
472    #[inline]
473    pub unsafe fn add_serialization_override(
474        &self,
475        obj_type: CFTypeID,
476        serialization_proc: WSMethodInvocationSerializationProcPtr,
477        context: *mut WSClientContext,
478    ) {
479        extern "C-unwind" {
480            fn WSMethodInvocationAddSerializationOverride(
481                invocation: &WSMethodInvocation,
482                obj_type: CFTypeID,
483                serialization_proc: WSMethodInvocationSerializationProcPtr,
484                context: *mut WSClientContext,
485            );
486        }
487        unsafe {
488            WSMethodInvocationAddSerializationOverride(self, obj_type, serialization_proc, context)
489        }
490    }
491}
492
493/// [Apple's documentation](https://developer.apple.com/documentation/coreservices/wsmethodinvocationdeserializationprocptr?language=objc)
494#[deprecated = "No longer supported"]
495pub type WSMethodInvocationDeserializationProcPtr = Option<
496    unsafe extern "C-unwind" fn(
497        *mut WSMethodInvocation,
498        *mut CFXMLTree,
499        *mut CFXMLTree,
500        *mut c_void,
501    ) -> *const CFType,
502>;
503
504impl WSMethodInvocation {
505    /// # Safety
506    ///
507    /// - `type_namespace` might not allow `None`.
508    /// - `type_name` might not allow `None`.
509    /// - `deserialization_proc` must be implemented correctly.
510    /// - `context` must be a valid pointer.
511    #[doc(alias = "WSMethodInvocationAddDeserializationOverride")]
512    #[cfg(feature = "WSTypes")]
513    #[deprecated = "No longer supported"]
514    #[inline]
515    pub unsafe fn add_deserialization_override(
516        &self,
517        type_namespace: Option<&CFString>,
518        type_name: Option<&CFString>,
519        deserialization_proc: WSMethodInvocationDeserializationProcPtr,
520        context: *mut WSClientContext,
521    ) {
522        extern "C-unwind" {
523            fn WSMethodInvocationAddDeserializationOverride(
524                invocation: &WSMethodInvocation,
525                type_namespace: Option<&CFString>,
526                type_name: Option<&CFString>,
527                deserialization_proc: WSMethodInvocationDeserializationProcPtr,
528                context: *mut WSClientContext,
529            );
530        }
531        unsafe {
532            WSMethodInvocationAddDeserializationOverride(
533                self,
534                type_namespace,
535                type_name,
536                deserialization_proc,
537                context,
538            )
539        }
540    }
541}
542
543#[deprecated = "renamed to `WSMethodInvocation::new`"]
544#[inline]
545pub unsafe extern "C-unwind" fn WSMethodInvocationCreate(
546    url: Option<&CFURL>,
547    method_name: Option<&CFString>,
548    protocol: Option<&CFString>,
549) -> Option<CFRetained<WSMethodInvocation>> {
550    extern "C-unwind" {
551        fn WSMethodInvocationCreate(
552            url: Option<&CFURL>,
553            method_name: Option<&CFString>,
554            protocol: Option<&CFString>,
555        ) -> Option<NonNull<WSMethodInvocation>>;
556    }
557    let ret = unsafe { WSMethodInvocationCreate(url, method_name, protocol) };
558    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
559}
560
561#[deprecated = "renamed to `WSMethodInvocation::from_serialization`"]
562#[inline]
563pub unsafe extern "C-unwind" fn WSMethodInvocationCreateFromSerialization(
564    contract: Option<&CFData>,
565) -> Option<CFRetained<WSMethodInvocation>> {
566    extern "C-unwind" {
567        fn WSMethodInvocationCreateFromSerialization(
568            contract: Option<&CFData>,
569        ) -> Option<NonNull<WSMethodInvocation>>;
570    }
571    let ret = unsafe { WSMethodInvocationCreateFromSerialization(contract) };
572    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
573}
574
575#[deprecated = "renamed to `WSMethodInvocation::serialization`"]
576#[inline]
577pub unsafe extern "C-unwind" fn WSMethodInvocationCopySerialization(
578    invocation: &WSMethodInvocation,
579) -> Option<CFRetained<CFData>> {
580    extern "C-unwind" {
581        fn WSMethodInvocationCopySerialization(
582            invocation: &WSMethodInvocation,
583        ) -> Option<NonNull<CFData>>;
584    }
585    let ret = unsafe { WSMethodInvocationCopySerialization(invocation) };
586    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
587}
588
589extern "C-unwind" {
590    #[deprecated = "renamed to `WSMethodInvocation::set_parameters`"]
591    pub fn WSMethodInvocationSetParameters(
592        invocation: &WSMethodInvocation,
593        parameters: Option<&CFDictionary>,
594        parameter_order: Option<&CFArray>,
595    );
596}
597
598#[deprecated = "renamed to `WSMethodInvocation::parameters`"]
599#[inline]
600pub unsafe extern "C-unwind" fn WSMethodInvocationCopyParameters(
601    invocation: &WSMethodInvocation,
602    parameter_order: *mut *const CFArray,
603) -> Option<CFRetained<CFDictionary>> {
604    extern "C-unwind" {
605        fn WSMethodInvocationCopyParameters(
606            invocation: &WSMethodInvocation,
607            parameter_order: *mut *const CFArray,
608        ) -> Option<NonNull<CFDictionary>>;
609    }
610    let ret = unsafe { WSMethodInvocationCopyParameters(invocation, parameter_order) };
611    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
612}
613
614extern "C-unwind" {
615    #[deprecated = "renamed to `WSMethodInvocation::set_property`"]
616    pub fn WSMethodInvocationSetProperty(
617        invocation: &WSMethodInvocation,
618        property_name: Option<&CFString>,
619        property_value: Option<&CFType>,
620    );
621}
622
623#[deprecated = "renamed to `WSMethodInvocation::property`"]
624#[inline]
625pub unsafe extern "C-unwind" fn WSMethodInvocationCopyProperty(
626    invocation: &WSMethodInvocation,
627    property_name: Option<&CFString>,
628) -> Option<CFRetained<CFType>> {
629    extern "C-unwind" {
630        fn WSMethodInvocationCopyProperty(
631            invocation: &WSMethodInvocation,
632            property_name: Option<&CFString>,
633        ) -> Option<NonNull<CFType>>;
634    }
635    let ret = unsafe { WSMethodInvocationCopyProperty(invocation, property_name) };
636    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
637}
638
639#[deprecated = "renamed to `WSMethodInvocation::invoke`"]
640#[inline]
641pub unsafe extern "C-unwind" fn WSMethodInvocationInvoke(
642    invocation: &WSMethodInvocation,
643) -> Option<CFRetained<CFDictionary>> {
644    extern "C-unwind" {
645        fn WSMethodInvocationInvoke(
646            invocation: &WSMethodInvocation,
647        ) -> Option<NonNull<CFDictionary>>;
648    }
649    let ret = unsafe { WSMethodInvocationInvoke(invocation) };
650    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
651}
652
653extern "C-unwind" {
654    #[cfg(feature = "WSTypes")]
655    #[deprecated = "renamed to `WSMethodInvocation::set_call_back`"]
656    pub fn WSMethodInvocationSetCallBack(
657        invocation: &WSMethodInvocation,
658        client_cb: WSMethodInvocationCallBackProcPtr,
659        context: *mut WSClientContext,
660    );
661}
662
663extern "C-unwind" {
664    #[deprecated = "renamed to `WSMethodInvocation::schedule_with_run_loop`"]
665    pub fn WSMethodInvocationScheduleWithRunLoop(
666        invocation: &WSMethodInvocation,
667        run_loop: Option<&CFRunLoop>,
668        run_loop_mode: Option<&CFString>,
669    );
670}
671
672extern "C-unwind" {
673    #[deprecated = "renamed to `WSMethodInvocation::unschedule_from_run_loop`"]
674    pub fn WSMethodInvocationUnscheduleFromRunLoop(
675        invocation: &WSMethodInvocation,
676        run_loop: Option<&CFRunLoop>,
677        run_loop_mode: Option<&CFString>,
678    );
679}
680
681extern "C-unwind" {
682    #[cfg(feature = "WSTypes")]
683    #[deprecated = "renamed to `WSMethodInvocation::add_serialization_override`"]
684    pub fn WSMethodInvocationAddSerializationOverride(
685        invocation: &WSMethodInvocation,
686        obj_type: CFTypeID,
687        serialization_proc: WSMethodInvocationSerializationProcPtr,
688        context: *mut WSClientContext,
689    );
690}
691
692extern "C-unwind" {
693    #[cfg(feature = "WSTypes")]
694    #[deprecated = "renamed to `WSMethodInvocation::add_deserialization_override`"]
695    pub fn WSMethodInvocationAddDeserializationOverride(
696        invocation: &WSMethodInvocation,
697        type_namespace: Option<&CFString>,
698        type_name: Option<&CFString>,
699        deserialization_proc: WSMethodInvocationDeserializationProcPtr,
700        context: *mut WSClientContext,
701    );
702}