1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use objc2::__framework_prelude::*;

use crate::*;

// NS_OPTIONS
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct NSXMLNodeOptions(pub NSUInteger);
impl NSXMLNodeOptions {
    #[doc(alias = "NSXMLNodeOptionsNone")]
    pub const None: Self = Self(0);
    pub const NSXMLNodeIsCDATA: Self = Self(1 << 0);
    pub const NSXMLNodeExpandEmptyElement: Self = Self(1 << 1);
    pub const NSXMLNodeCompactEmptyElement: Self = Self(1 << 2);
    pub const NSXMLNodeUseSingleQuotes: Self = Self(1 << 3);
    pub const NSXMLNodeUseDoubleQuotes: Self = Self(1 << 4);
    pub const NSXMLNodeNeverEscapeContents: Self = Self(1 << 5);
    pub const NSXMLDocumentTidyHTML: Self = Self(1 << 9);
    pub const NSXMLDocumentTidyXML: Self = Self(1 << 10);
    pub const NSXMLDocumentValidate: Self = Self(1 << 13);
    pub const NSXMLNodeLoadExternalEntitiesAlways: Self = Self(1 << 14);
    pub const NSXMLNodeLoadExternalEntitiesSameOriginOnly: Self = Self(1 << 15);
    pub const NSXMLNodeLoadExternalEntitiesNever: Self = Self(1 << 19);
    pub const NSXMLDocumentXInclude: Self = Self(1 << 16);
    pub const NSXMLNodePrettyPrint: Self = Self(1 << 17);
    pub const NSXMLDocumentIncludeContentTypeDeclaration: Self = Self(1 << 18);
    pub const NSXMLNodePreserveNamespaceOrder: Self = Self(1 << 20);
    pub const NSXMLNodePreserveAttributeOrder: Self = Self(1 << 21);
    pub const NSXMLNodePreserveEntities: Self = Self(1 << 22);
    pub const NSXMLNodePreservePrefixes: Self = Self(1 << 23);
    pub const NSXMLNodePreserveCDATA: Self = Self(1 << 24);
    pub const NSXMLNodePreserveWhitespace: Self = Self(1 << 25);
    pub const NSXMLNodePreserveDTD: Self = Self(1 << 26);
    pub const NSXMLNodePreserveCharacterReferences: Self = Self(1 << 27);
    pub const NSXMLNodePromoteSignificantWhitespace: Self = Self(1 << 28);
    pub const NSXMLNodePreserveEmptyElements: Self = Self(
        NSXMLNodeOptions::NSXMLNodeExpandEmptyElement.0
            | NSXMLNodeOptions::NSXMLNodeCompactEmptyElement.0,
    );
    pub const NSXMLNodePreserveQuotes: Self = Self(
        NSXMLNodeOptions::NSXMLNodeUseSingleQuotes.0 | NSXMLNodeOptions::NSXMLNodeUseDoubleQuotes.0,
    );
    pub const NSXMLNodePreserveAll: Self = Self(
        NSXMLNodeOptions::NSXMLNodePreserveNamespaceOrder.0
            | NSXMLNodeOptions::NSXMLNodePreserveAttributeOrder.0
            | NSXMLNodeOptions::NSXMLNodePreserveEntities.0
            | NSXMLNodeOptions::NSXMLNodePreservePrefixes.0
            | NSXMLNodeOptions::NSXMLNodePreserveCDATA.0
            | NSXMLNodeOptions::NSXMLNodePreserveEmptyElements.0
            | NSXMLNodeOptions::NSXMLNodePreserveQuotes.0
            | NSXMLNodeOptions::NSXMLNodePreserveWhitespace.0
            | NSXMLNodeOptions::NSXMLNodePreserveDTD.0
            | NSXMLNodeOptions::NSXMLNodePreserveCharacterReferences.0
            | 0xFFF00000,
    );
}

unsafe impl Encode for NSXMLNodeOptions {
    const ENCODING: Encoding = NSUInteger::ENCODING;
}

unsafe impl RefEncode for NSXMLNodeOptions {
    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}