-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathxml-document-structure.json
More file actions
113 lines (113 loc) · 3.43 KB
/
xml-document-structure.json
File metadata and controls
113 lines (113 loc) · 3.43 KB
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
{
"$schema": "https://json-structure.org/draft-01/json-structure-core.json",
"$id": "https://raw.githubusercontent.com/api-evangelist/xml/refs/heads/main/json-structure/xml-document-structure.json",
"title": "XML Document Structure",
"description": "Structural reference describing the canonical hierarchy of an XML document: prolog, optional doctype declaration, optional processing instructions and comments, and a single root element with namespaces, attributes, and child content.",
"type": "object",
"properties": {
"prolog": {
"type": "object",
"description": "The XML declaration appearing at the beginning of the document.",
"properties": {
"version": {
"type": "string",
"enum": ["1.0", "1.1"],
"description": "XML version."
},
"encoding": {
"type": "string",
"description": "Character encoding name."
},
"standalone": {
"type": "boolean",
"description": "Standalone document declaration."
}
},
"required": ["version"]
},
"doctype": {
"type": "object",
"description": "Optional Document Type Declaration.",
"properties": {
"name": { "type": "string" },
"publicId": { "type": "string" },
"systemId": { "type": "string" },
"internalSubset": { "type": "string" }
}
},
"miscBeforeRoot": {
"type": "array",
"description": "Comments and processing instructions allowed between the prolog and root element.",
"items": {
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": ["comment", "processing-instruction"]
},
"value": { "type": "string" }
},
"required": ["kind"]
}
},
"rootElement": {
"type": "object",
"description": "The single root element of the document.",
"properties": {
"qualifiedName": { "type": "string" },
"namespaces": {
"type": "array",
"items": {
"type": "object",
"properties": {
"prefix": { "type": "string" },
"uri": { "type": "string", "format": "uri" }
},
"required": ["uri"]
}
},
"attributes": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": { "type": "string" },
"value": { "type": "string" }
},
"required": ["name", "value"]
}
},
"children": {
"type": "array",
"items": {
"type": "object",
"properties": {
"nodeType": {
"type": "string",
"enum": ["element", "text", "cdata", "comment", "processing-instruction"]
}
},
"required": ["nodeType"]
}
}
},
"required": ["qualifiedName"]
},
"miscAfterRoot": {
"type": "array",
"description": "Comments and processing instructions allowed after the root element.",
"items": {
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": ["comment", "processing-instruction"]
},
"value": { "type": "string" }
},
"required": ["kind"]
}
}
},
"required": ["prolog", "rootElement"]
}