objc2_core_foundation/generated/
CFCharacterSet.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::*;
9
10use crate::*;
11
12/// This is the type of a reference to immutable CFCharacterSets.
13///
14/// See also [Apple's documentation](https://developer.apple.com/documentation/corefoundation/cfcharacterset?language=objc)
15#[repr(C)]
16pub struct CFCharacterSet {
17    inner: [u8; 0],
18    _p: UnsafeCell<PhantomData<(*const UnsafeCell<()>, PhantomPinned)>>,
19}
20
21cf_type!(
22    #[encoding_name = "__CFCharacterSet"]
23    unsafe impl CFCharacterSet {}
24);
25
26/// This is the type of a reference to mutable CFMutableCharacterSets.
27///
28/// See also [Apple's documentation](https://developer.apple.com/documentation/corefoundation/cfmutablecharacterset?language=objc)
29#[repr(C)]
30pub struct CFMutableCharacterSet {
31    inner: [u8; 0],
32    _p: UnsafeCell<PhantomData<(*const UnsafeCell<()>, PhantomPinned)>>,
33}
34
35cf_type!(
36    #[encoding_name = "__CFCharacterSet"]
37    unsafe impl CFMutableCharacterSet: CFCharacterSet {}
38);
39
40/// Type of the predefined CFCharacterSet selector values.
41///
42/// See also [Apple's documentation](https://developer.apple.com/documentation/corefoundation/cfcharactersetpredefinedset?language=objc)
43// NS_ENUM
44#[cfg(feature = "CFBase")]
45#[repr(transparent)]
46#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
47pub struct CFCharacterSetPredefinedSet(pub CFIndex);
48#[cfg(feature = "CFBase")]
49impl CFCharacterSetPredefinedSet {
50    #[doc(alias = "kCFCharacterSetControl")]
51    pub const Control: Self = Self(1);
52    #[doc(alias = "kCFCharacterSetWhitespace")]
53    pub const Whitespace: Self = Self(2);
54    #[doc(alias = "kCFCharacterSetWhitespaceAndNewline")]
55    pub const WhitespaceAndNewline: Self = Self(3);
56    #[doc(alias = "kCFCharacterSetDecimalDigit")]
57    pub const DecimalDigit: Self = Self(4);
58    #[doc(alias = "kCFCharacterSetLetter")]
59    pub const Letter: Self = Self(5);
60    #[doc(alias = "kCFCharacterSetLowercaseLetter")]
61    pub const LowercaseLetter: Self = Self(6);
62    #[doc(alias = "kCFCharacterSetUppercaseLetter")]
63    pub const UppercaseLetter: Self = Self(7);
64    #[doc(alias = "kCFCharacterSetNonBase")]
65    pub const NonBase: Self = Self(8);
66    #[doc(alias = "kCFCharacterSetDecomposable")]
67    pub const Decomposable: Self = Self(9);
68    #[doc(alias = "kCFCharacterSetAlphaNumeric")]
69    pub const AlphaNumeric: Self = Self(10);
70    #[doc(alias = "kCFCharacterSetPunctuation")]
71    pub const Punctuation: Self = Self(11);
72    #[doc(alias = "kCFCharacterSetCapitalizedLetter")]
73    pub const CapitalizedLetter: Self = Self(13);
74    #[doc(alias = "kCFCharacterSetSymbol")]
75    pub const Symbol: Self = Self(14);
76    #[doc(alias = "kCFCharacterSetNewline")]
77    pub const Newline: Self = Self(15);
78    #[doc(alias = "kCFCharacterSetIllegal")]
79    pub const Illegal: Self = Self(12);
80}
81
82#[cfg(all(feature = "CFBase", feature = "objc2"))]
83unsafe impl Encode for CFCharacterSetPredefinedSet {
84    const ENCODING: Encoding = CFIndex::ENCODING;
85}
86
87#[cfg(all(feature = "CFBase", feature = "objc2"))]
88unsafe impl RefEncode for CFCharacterSetPredefinedSet {
89    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
90}
91
92#[cfg(feature = "CFBase")]
93unsafe impl ConcreteType for CFCharacterSet {
94    /// Returns the type identifier of all CFCharacterSet instances.
95    #[doc(alias = "CFCharacterSetGetTypeID")]
96    #[inline]
97    fn type_id() -> CFTypeID {
98        extern "C-unwind" {
99            fn CFCharacterSetGetTypeID() -> CFTypeID;
100        }
101        unsafe { CFCharacterSetGetTypeID() }
102    }
103}
104
105/// Returns a predefined CFCharacterSet instance.
106///
107/// Parameter `theSetIdentifier`: The CFCharacterSetPredefinedSet selector
108/// which specifies the predefined character set.  If the
109/// value is not in CFCharacterSetPredefinedSet, the behavior
110/// is undefined.
111///
112/// Returns: A reference to the predefined immutable CFCharacterSet.
113/// This instance is owned by CF.
114#[cfg(feature = "CFBase")]
115#[inline]
116pub unsafe extern "C-unwind" fn CFCharacterSetGetPredefined(
117    the_set_identifier: CFCharacterSetPredefinedSet,
118) -> Option<CFRetained<CFCharacterSet>> {
119    extern "C-unwind" {
120        fn CFCharacterSetGetPredefined(
121            the_set_identifier: CFCharacterSetPredefinedSet,
122        ) -> Option<NonNull<CFCharacterSet>>;
123    }
124    let ret = unsafe { CFCharacterSetGetPredefined(the_set_identifier) };
125    ret.map(|ret| unsafe { CFRetained::retain(ret) })
126}
127
128/// Creates a new immutable character set with the values from the given range.
129///
130/// Parameter `alloc`: The CFAllocator which should be used to allocate
131/// memory for the array and its storage for values. This
132/// parameter may be NULL in which case the current default
133/// CFAllocator is used. If this reference is not a valid
134/// CFAllocator, the behavior is undefined.
135///
136/// Parameter `theRange`: The CFRange which should be used to specify the
137/// Unicode range the character set is filled with.  It
138/// accepts the range in 32-bit in the UTF-32 format.  The
139/// valid character point range is from 0x00000 to 0x10FFFF.
140/// If the range is outside of the valid Unicode character
141/// point, the behavior is undefined.
142///
143/// Returns: A reference to the new immutable CFCharacterSet.
144#[cfg(feature = "CFBase")]
145#[inline]
146pub unsafe extern "C-unwind" fn CFCharacterSetCreateWithCharactersInRange(
147    alloc: Option<&CFAllocator>,
148    the_range: CFRange,
149) -> Option<CFRetained<CFCharacterSet>> {
150    extern "C-unwind" {
151        fn CFCharacterSetCreateWithCharactersInRange(
152            alloc: Option<&CFAllocator>,
153            the_range: CFRange,
154        ) -> Option<NonNull<CFCharacterSet>>;
155    }
156    let ret = unsafe { CFCharacterSetCreateWithCharactersInRange(alloc, the_range) };
157    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
158}
159
160/// Creates a new immutable character set with the values in the given string.
161///
162/// Parameter `alloc`: The CFAllocator which should be used to allocate
163/// memory for the array and its storage for values. This
164/// parameter may be NULL in which case the current default
165/// CFAllocator is used. If this reference is not a valid
166/// CFAllocator, the behavior is undefined.
167///
168/// Parameter `theString`: The CFString which should be used to specify
169/// the Unicode characters the character set is filled with.
170/// If this parameter is not a valid CFString, the behavior
171/// is undefined.
172///
173/// Returns: A reference to the new immutable CFCharacterSet.
174#[cfg(feature = "CFBase")]
175#[inline]
176pub unsafe extern "C-unwind" fn CFCharacterSetCreateWithCharactersInString(
177    alloc: Option<&CFAllocator>,
178    the_string: Option<&CFString>,
179) -> Option<CFRetained<CFCharacterSet>> {
180    extern "C-unwind" {
181        fn CFCharacterSetCreateWithCharactersInString(
182            alloc: Option<&CFAllocator>,
183            the_string: Option<&CFString>,
184        ) -> Option<NonNull<CFCharacterSet>>;
185    }
186    let ret = unsafe { CFCharacterSetCreateWithCharactersInString(alloc, the_string) };
187    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
188}
189
190/// Creates a new immutable character set with the bitmap representtion in the given data.
191///
192/// Parameter `alloc`: The CFAllocator which should be used to allocate
193/// memory for the array and its storage for values. This
194/// parameter may be NULL in which case the current default
195/// CFAllocator is used. If this reference is not a valid
196/// CFAllocator, the behavior is undefined.
197///
198/// Parameter `theData`: The CFData which should be used to specify the
199/// bitmap representation of the Unicode character points
200/// the character set is filled with.  The bitmap
201/// representation could contain all the Unicode character
202/// range starting from BMP to Plane 16.  The first 8192 bytes
203/// of the data represent the BMP range.  The BMP range 8192
204/// bytes can be followed by zero to sixteen 8192 byte
205/// bitmaps, each one with the plane index byte prepended.
206/// For example, the bitmap representing the BMP and Plane 2
207/// has the size of 16385 bytes (8192 bytes for BMP, 1 byte
208/// index + 8192 bytes bitmap for Plane 2).  The plane index
209/// byte, in this case, contains the integer value two.  If
210/// this parameter is not a valid CFData or it contains a
211/// Plane index byte outside of the valid Plane range
212/// (1 to 16), the behavior is undefined.
213///
214/// Returns: A reference to the new immutable CFCharacterSet.
215#[cfg(all(feature = "CFBase", feature = "CFData"))]
216#[inline]
217pub unsafe extern "C-unwind" fn CFCharacterSetCreateWithBitmapRepresentation(
218    alloc: Option<&CFAllocator>,
219    the_data: Option<&CFData>,
220) -> Option<CFRetained<CFCharacterSet>> {
221    extern "C-unwind" {
222        fn CFCharacterSetCreateWithBitmapRepresentation(
223            alloc: Option<&CFAllocator>,
224            the_data: Option<&CFData>,
225        ) -> Option<NonNull<CFCharacterSet>>;
226    }
227    let ret = unsafe { CFCharacterSetCreateWithBitmapRepresentation(alloc, the_data) };
228    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
229}
230
231/// Creates a new immutable character set that is the invert of the specified character set.
232///
233/// Parameter `alloc`: The CFAllocator which should be used to allocate
234/// memory for the array and its storage for values. This
235/// parameter may be NULL in which case the current default
236/// CFAllocator is used. If this reference is not a valid
237/// CFAllocator, the behavior is undefined.
238///
239/// Parameter `theSet`: The CFCharacterSet which is to be inverted.  If this
240/// parameter is not a valid CFCharacterSet, the behavior is
241/// undefined.
242///
243/// Returns: A reference to the new immutable CFCharacterSet.
244#[cfg(feature = "CFBase")]
245#[inline]
246pub unsafe extern "C-unwind" fn CFCharacterSetCreateInvertedSet(
247    alloc: Option<&CFAllocator>,
248    the_set: Option<&CFCharacterSet>,
249) -> Option<CFRetained<CFCharacterSet>> {
250    extern "C-unwind" {
251        fn CFCharacterSetCreateInvertedSet(
252            alloc: Option<&CFAllocator>,
253            the_set: Option<&CFCharacterSet>,
254        ) -> Option<NonNull<CFCharacterSet>>;
255    }
256    let ret = unsafe { CFCharacterSetCreateInvertedSet(alloc, the_set) };
257    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
258}
259
260/// Reports whether or not the character set is a superset of the character set specified as the second parameter.
261///
262/// Parameter `theSet`: The character set to be checked for the membership of theOtherSet.
263/// If this parameter is not a valid CFCharacterSet, the behavior is undefined.
264///
265/// Parameter `theOtherset`: The character set to be checked whether or not it is a subset of theSet.
266/// If this parameter is not a valid CFCharacterSet, the behavior is undefined.
267#[inline]
268pub unsafe extern "C-unwind" fn CFCharacterSetIsSupersetOfSet(
269    the_set: &CFCharacterSet,
270    the_otherset: Option<&CFCharacterSet>,
271) -> bool {
272    extern "C-unwind" {
273        fn CFCharacterSetIsSupersetOfSet(
274            the_set: &CFCharacterSet,
275            the_otherset: Option<&CFCharacterSet>,
276        ) -> Boolean;
277    }
278    let ret = unsafe { CFCharacterSetIsSupersetOfSet(the_set, the_otherset) };
279    ret != 0
280}
281
282/// Reports whether or not the character set contains at least one member character in the specified plane.
283///
284/// Parameter `theSet`: The character set to be checked for the membership.  If this
285/// parameter is not a valid CFCharacterSet, the behavior is undefined.
286///
287/// Parameter `thePlane`: The plane number to be checked for the membership.
288/// The valid value range is from 0 to 16.  If the value is outside of the valid
289/// plane number range, the behavior is undefined.
290#[cfg(feature = "CFBase")]
291#[inline]
292pub unsafe extern "C-unwind" fn CFCharacterSetHasMemberInPlane(
293    the_set: &CFCharacterSet,
294    the_plane: CFIndex,
295) -> bool {
296    extern "C-unwind" {
297        fn CFCharacterSetHasMemberInPlane(the_set: &CFCharacterSet, the_plane: CFIndex) -> Boolean;
298    }
299    let ret = unsafe { CFCharacterSetHasMemberInPlane(the_set, the_plane) };
300    ret != 0
301}
302
303/// Creates a new empty mutable character set.
304///
305/// Parameter `alloc`: The CFAllocator which should be used to allocate
306/// memory for the array and its storage for values. This
307/// parameter may be NULL in which case the current default
308/// CFAllocator is used. If this reference is not a valid
309/// CFAllocator, the behavior is undefined.
310///
311/// Returns: A reference to the new mutable CFCharacterSet.
312#[cfg(feature = "CFBase")]
313#[inline]
314pub unsafe extern "C-unwind" fn CFCharacterSetCreateMutable(
315    alloc: Option<&CFAllocator>,
316) -> Option<CFRetained<CFMutableCharacterSet>> {
317    extern "C-unwind" {
318        fn CFCharacterSetCreateMutable(
319            alloc: Option<&CFAllocator>,
320        ) -> Option<NonNull<CFMutableCharacterSet>>;
321    }
322    let ret = unsafe { CFCharacterSetCreateMutable(alloc) };
323    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
324}
325
326/// Creates a new character set with the values from the given character set.  This function tries to compact the backing store where applicable.
327///
328/// Parameter `alloc`: The CFAllocator which should be used to allocate
329/// memory for the array and its storage for values. This
330/// parameter may be NULL in which case the current default
331/// CFAllocator is used. If this reference is not a valid
332/// CFAllocator, the behavior is undefined.
333///
334/// Parameter `theSet`: The CFCharacterSet which is to be copied.  If this
335/// parameter is not a valid CFCharacterSet, the behavior is
336/// undefined.
337///
338/// Returns: A reference to the new CFCharacterSet.
339#[cfg(feature = "CFBase")]
340#[inline]
341pub unsafe extern "C-unwind" fn CFCharacterSetCreateCopy(
342    alloc: Option<&CFAllocator>,
343    the_set: Option<&CFCharacterSet>,
344) -> Option<CFRetained<CFCharacterSet>> {
345    extern "C-unwind" {
346        fn CFCharacterSetCreateCopy(
347            alloc: Option<&CFAllocator>,
348            the_set: Option<&CFCharacterSet>,
349        ) -> Option<NonNull<CFCharacterSet>>;
350    }
351    let ret = unsafe { CFCharacterSetCreateCopy(alloc, the_set) };
352    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
353}
354
355/// Creates a new mutable character set with the values from the given character set.
356///
357/// Parameter `alloc`: The CFAllocator which should be used to allocate
358/// memory for the array and its storage for values. This
359/// parameter may be NULL in which case the current default
360/// CFAllocator is used. If this reference is not a valid
361/// CFAllocator, the behavior is undefined.
362///
363/// Parameter `theSet`: The CFCharacterSet which is to be copied.  If this
364/// parameter is not a valid CFCharacterSet, the behavior is
365/// undefined.
366///
367/// Returns: A reference to the new mutable CFCharacterSet.
368#[cfg(feature = "CFBase")]
369#[inline]
370pub unsafe extern "C-unwind" fn CFCharacterSetCreateMutableCopy(
371    alloc: Option<&CFAllocator>,
372    the_set: Option<&CFCharacterSet>,
373) -> Option<CFRetained<CFMutableCharacterSet>> {
374    extern "C-unwind" {
375        fn CFCharacterSetCreateMutableCopy(
376            alloc: Option<&CFAllocator>,
377            the_set: Option<&CFCharacterSet>,
378        ) -> Option<NonNull<CFMutableCharacterSet>>;
379    }
380    let ret = unsafe { CFCharacterSetCreateMutableCopy(alloc, the_set) };
381    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
382}
383
384/// Reports whether or not the Unicode character is in the character set.
385///
386/// Parameter `theSet`: The character set to be searched. If this parameter
387/// is not a valid CFCharacterSet, the behavior is undefined.
388///
389/// Parameter `theChar`: The Unicode character for which to test against the
390/// character set.  Note that this function takes 16-bit Unicode
391/// character value; hence, it does not support access to the
392/// non-BMP planes.
393///
394/// Returns: true, if the value is in the character set, otherwise false.
395#[inline]
396pub unsafe extern "C-unwind" fn CFCharacterSetIsCharacterMember(
397    the_set: &CFCharacterSet,
398    the_char: UniChar,
399) -> bool {
400    extern "C-unwind" {
401        fn CFCharacterSetIsCharacterMember(the_set: &CFCharacterSet, the_char: UniChar) -> Boolean;
402    }
403    let ret = unsafe { CFCharacterSetIsCharacterMember(the_set, the_char) };
404    ret != 0
405}
406
407/// Reports whether or not the UTF-32 character is in the character set.
408///
409/// Parameter `theSet`: The character set to be searched. If this parameter
410/// is not a valid CFCharacterSet, the behavior is undefined.
411///
412/// Parameter `theChar`: The UTF-32 character for which to test against the
413/// character set.
414///
415/// Returns: true, if the value is in the character set, otherwise false.
416#[inline]
417pub unsafe extern "C-unwind" fn CFCharacterSetIsLongCharacterMember(
418    the_set: &CFCharacterSet,
419    the_char: UTF32Char,
420) -> bool {
421    extern "C-unwind" {
422        fn CFCharacterSetIsLongCharacterMember(
423            the_set: &CFCharacterSet,
424            the_char: UTF32Char,
425        ) -> Boolean;
426    }
427    let ret = unsafe { CFCharacterSetIsLongCharacterMember(the_set, the_char) };
428    ret != 0
429}
430
431/// Creates a new immutable data with the bitmap representation from the given character set.
432///
433/// Parameter `alloc`: The CFAllocator which should be used to allocate
434/// memory for the array and its storage for values. This
435/// parameter may be NULL in which case the current default
436/// CFAllocator is used. If this reference is not a valid
437/// CFAllocator, the behavior is undefined.
438///
439/// Parameter `theSet`: The CFCharacterSet which is to be used create the
440/// bitmap representation from.  Refer to the comments for
441/// CFCharacterSetCreateWithBitmapRepresentation for the
442/// detailed discussion of the bitmap representation format.
443/// If this parameter is not a valid CFCharacterSet, the
444/// behavior is undefined.
445///
446/// Returns: A reference to the new immutable CFData.
447#[cfg(all(feature = "CFBase", feature = "CFData"))]
448#[inline]
449pub unsafe extern "C-unwind" fn CFCharacterSetCreateBitmapRepresentation(
450    alloc: Option<&CFAllocator>,
451    the_set: Option<&CFCharacterSet>,
452) -> Option<CFRetained<CFData>> {
453    extern "C-unwind" {
454        fn CFCharacterSetCreateBitmapRepresentation(
455            alloc: Option<&CFAllocator>,
456            the_set: Option<&CFCharacterSet>,
457        ) -> Option<NonNull<CFData>>;
458    }
459    let ret = unsafe { CFCharacterSetCreateBitmapRepresentation(alloc, the_set) };
460    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
461}
462
463extern "C-unwind" {
464    /// Adds the given range to the charaacter set.
465    ///
466    /// Parameter `theSet`: The character set to which the range is to be added.
467    /// If this parameter is not a valid mutable CFCharacterSet,
468    /// the behavior is undefined.
469    ///
470    /// Parameter `theRange`: The range to add to the character set.  It accepts
471    /// the range in 32-bit in the UTF-32 format.  The valid
472    /// character point range is from 0x00000 to 0x10FFFF.  If the
473    /// range is outside of the valid Unicode character point,
474    /// the behavior is undefined.
475    #[cfg(feature = "CFBase")]
476    pub fn CFCharacterSetAddCharactersInRange(
477        the_set: Option<&CFMutableCharacterSet>,
478        the_range: CFRange,
479    );
480}
481
482extern "C-unwind" {
483    /// Removes the given range from the charaacter set.
484    ///
485    /// Parameter `theSet`: The character set from which the range is to be
486    /// removed.  If this parameter is not a valid mutable
487    /// CFCharacterSet, the behavior is undefined.
488    ///
489    /// Parameter `theRange`: The range to remove from the character set.
490    /// It accepts the range in 32-bit in the UTF-32 format.
491    /// The valid character point range is from 0x00000 to 0x10FFFF.
492    /// If the range is outside of the valid Unicode character point,
493    /// the behavior is undefined.
494    #[cfg(feature = "CFBase")]
495    pub fn CFCharacterSetRemoveCharactersInRange(
496        the_set: Option<&CFMutableCharacterSet>,
497        the_range: CFRange,
498    );
499}
500
501extern "C-unwind" {
502    /// Adds the characters in the given string to the charaacter set.
503    ///
504    /// Parameter `theSet`: The character set to which the characters in the
505    /// string are to be added.  If this parameter is not a
506    /// valid mutable CFCharacterSet, the behavior is undefined.
507    ///
508    /// Parameter `theString`: The string to add to the character set.
509    /// If this parameter is not a valid CFString, the behavior
510    /// is undefined.
511    #[cfg(feature = "CFBase")]
512    pub fn CFCharacterSetAddCharactersInString(
513        the_set: Option<&CFMutableCharacterSet>,
514        the_string: Option<&CFString>,
515    );
516}
517
518extern "C-unwind" {
519    /// Removes the characters in the given string from the charaacter set.
520    ///
521    /// Parameter `theSet`: The character set from which the characters in the
522    /// string are to be remove.  If this parameter is not a
523    /// valid mutable CFCharacterSet, the behavior is undefined.
524    ///
525    /// Parameter `theString`: The string to remove from the character set.
526    /// If this parameter is not a valid CFString, the behavior
527    /// is undefined.
528    #[cfg(feature = "CFBase")]
529    pub fn CFCharacterSetRemoveCharactersInString(
530        the_set: Option<&CFMutableCharacterSet>,
531        the_string: Option<&CFString>,
532    );
533}
534
535extern "C-unwind" {
536    /// Forms the union with the given character set.
537    ///
538    /// Parameter `theSet`: The destination character set into which the
539    /// union of the two character sets is stored.  If this
540    /// parameter is not a valid mutable CFCharacterSet, the
541    /// behavior is undefined.
542    ///
543    /// Parameter `theOtherSet`: The character set with which the union is
544    /// formed.  If this parameter is not a valid CFCharacterSet,
545    /// the behavior is undefined.
546    pub fn CFCharacterSetUnion(
547        the_set: Option<&CFMutableCharacterSet>,
548        the_other_set: Option<&CFCharacterSet>,
549    );
550}
551
552extern "C-unwind" {
553    /// Forms the intersection with the given character set.
554    ///
555    /// Parameter `theSet`: The destination character set into which the
556    /// intersection of the two character sets is stored.
557    /// If this parameter is not a valid mutable CFCharacterSet,
558    /// the behavior is undefined.
559    ///
560    /// Parameter `theOtherSet`: The character set with which the intersection
561    /// is formed.  If this parameter is not a valid CFCharacterSet,
562    /// the behavior is undefined.
563    pub fn CFCharacterSetIntersect(
564        the_set: Option<&CFMutableCharacterSet>,
565        the_other_set: Option<&CFCharacterSet>,
566    );
567}
568
569extern "C-unwind" {
570    /// Inverts the content of the given character set.
571    ///
572    /// Parameter `theSet`: The character set to be inverted.
573    /// If this parameter is not a valid mutable CFCharacterSet,
574    /// the behavior is undefined.
575    pub fn CFCharacterSetInvert(the_set: Option<&CFMutableCharacterSet>);
576}