forked from chroma-sdk/Colore
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCustomDictionary.xsd
137 lines (125 loc) · 6.46 KB
/
CustomDictionary.xsd
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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<?xml version="1.0" encoding="utf-8"?>
<xs:schema
attributeFormDefault="unqualified"
elementFormDefault="qualified"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="Dictionary" type="DictionaryType" />
<xs:simpleType name="WordType">
<xs:restriction base="xs:string" />
</xs:simpleType>
<xs:simpleType name="TermType">
<xs:restriction base="xs:string" />
</xs:simpleType>
<xs:complexType name="DeprecatedTermType">
<xs:simpleContent>
<xs:extension base="TermType">
<xs:attribute name="PreferredAlternate" use="required" type="xs:string" />
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<xs:complexType name="CompoundTermType">
<xs:simpleContent>
<xs:extension base="TermType">
<xs:attribute name="CompoundAlternate" use="required" type="xs:string" />
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<xs:complexType name="DictionaryType">
<xs:sequence>
<xs:element name="Words" type="WordsType" minOccurs="0" maxOccurs="1" />
<xs:element name="Acronyms" type="AcronymsType" minOccurs="0" maxOccurs="1" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="WordsType">
<xs:sequence>
<xs:element name="Unrecognized" type="WordlistType" minOccurs="0" maxOccurs="1">
<xs:annotation>
<xs:documentation>
This is a list of case-insensitive words that exist in the dictionary
but you do not want to be recognized by IdentifiersShouldBeSpelledCorrectly.
Do not add deprecated terms to this list, instead add these to the Deprecated section.
</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="Recognized" type="WordlistType" minOccurs="0" maxOccurs="1">
<xs:annotation>
<xs:documentation>
This is a list of case-insensitive words that do not exist in the dictionary
but you still want to be considered as recognized by IdentifiersShouldBeSpelledCorrectly.
Do not add compound words (e.g. 'FileName')
to this list as this will cause CompoundWordsShouldBeBeCasedCorrectly to fire on
usages of the compound word stating that they should be changed to their discrete equivalent
(for example 'FileName' -> 'Filename').
</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="Deprecated" type="DeprecatedType" minOccurs="0" maxOccurs="1" />
<xs:element name="Compound" type="CompoundType" minOccurs="0" maxOccurs="1" />
<xs:element name="DiscreteExceptions" type="DiscreteType" minOccurs="0" maxOccurs="1" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="AcronymsType">
<xs:sequence>
<xs:element name="CasingExceptions" minOccurs="1" maxOccurs="1">
<xs:complexType>
<xs:sequence>
<xs:element name="Acronym" minOccurs="1" maxOccurs="unbounded" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="WordlistType">
<xs:sequence>
<xs:element name="Word" minOccurs="1" maxOccurs="unbounded" type="WordType" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="DeprecatedType">
<xs:annotation>
<xs:documentation>
This is a list of deprecated terms with their preferred alternates and is
used by UsePreferredTerms. The deprecated terms are case-insensitive,
however, make sure to pascal-case the preferred alternates. If a word
does not have a preferred alternate, simply leave it blank.
</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:element name="Term" minOccurs="1" maxOccurs="unbounded" type="DeprecatedTermType" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="CompoundType">
<xs:annotation>
<xs:documentation>
This is a list of discrete terms with their compound alternates and is used by
CompoundWordsShouldBeCasedCorrectly. These are words that exist in the
dictionary as discrete terms, however, should actually be cased as compound words.
For example, 'Filename' exists in the dictionary and hence the spelling rules will
not see it as unrecognized but its actual preferred usage is 'FileName'; adding it
below causes CompoundWordsShouldBeCasedCorrectly to fire. The discrete terms are
case-insensitive, however, be sure to pascal-case the compound alternates.
Any discrete terms added below automatically get added to the list of discrete
exceptions to prevent CompoundWordsShouldBeCasedCorrectly from firing both on the
compound word (for example 'WhiteSpace') and its discrete alternate (for example
'Whitespace').
</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:element name="Term" minOccurs="1" maxOccurs="unbounded" type="CompoundTermType" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="DiscreteType">
<xs:annotation>
<xs:documentation>
This is a list of case-insensitive exceptions to the CompoundWordsShouldBeCasedCorrectly
discrete term check. As this check works solely on the basis of whether two consecutive
tokens exists in the dictionary, it can have a high false positive rate. For example,
'onset' exists in the dictionary but the user probably intended it to be 'OnSet'.
Adding this word below prevents this rule from firing telling the user to change 'OnSet'
to 'Onset'.
</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:element name="Term" minOccurs="1" maxOccurs="unbounded" type="TermType" />
</xs:sequence>
</xs:complexType>
</xs:schema>