Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ AddToTable()

void System.Xml.Schema.BaseProcessor.AddToTable ( XmlSchemaObjectTable table,
XmlQualifiedName qname,
XmlSchemaObject item )
inlineprotectedinherited

Definition at line 51 of file BaseProcessor.cs.

52 {
53 if (qname.Name.Length == 0)
54 {
55 return;
56 }
57 XmlSchemaObject xmlSchemaObject = table[qname];
58 if (xmlSchemaObject != null)
59 {
60 if (xmlSchemaObject == item)
61 {
62 return;
63 }
65 if (item is XmlSchemaAttributeGroup)
66 {
67 string strA = _nameTable.Add(qname.Namespace);
68 if (Ref.Equal(strA, _nsXml))
69 {
70 XmlSchema buildInSchema = Preprocessor.GetBuildInSchema();
71 XmlSchemaObject xmlSchemaObject2 = buildInSchema.AttributeGroups[qname];
73 {
74 table.Insert(qname, item);
75 return;
76 }
78 {
79 return;
80 }
81 }
83 {
84 return;
85 }
87 }
88 else if (item is XmlSchemaAttribute)
89 {
90 string strA2 = _nameTable.Add(qname.Namespace);
91 if (Ref.Equal(strA2, _nsXml))
92 {
93 XmlSchema buildInSchema2 = Preprocessor.GetBuildInSchema();
94 XmlSchemaObject xmlSchemaObject3 = buildInSchema2.Attributes[qname];
96 {
97 table.Insert(qname, item);
98 return;
99 }
100 if (item == xmlSchemaObject3)
101 {
102 return;
103 }
104 }
106 }
107 else if (item is XmlSchemaSimpleType)
108 {
110 {
111 return;
112 }
114 }
115 else if (item is XmlSchemaComplexType)
116 {
118 {
119 return;
120 }
122 }
123 else if (item is XmlSchemaGroup)
124 {
126 {
127 return;
128 }
130 }
131 else if (item is XmlSchemaNotation)
132 {
134 }
135 else if (item is XmlSchemaIdentityConstraint)
136 {
138 }
139 SendValidationEvent(code, qname.ToString(), item);
140 }
141 else
142 {
143 table.Add(qname, item);
144 }
145 }
static string Sch_DupIdentityConstraint
Definition SR.cs:520
static string Sch_DupComplexType
Definition SR.cs:528
static string Sch_DupGlobalAttribute
Definition SR.cs:524
static string Sch_DupSimpleType
Definition SR.cs:526
static string Sch_DupGlobalElement
Definition SR.cs:522
static string Sch_DupAttributeGroup
Definition SR.cs:532
static string Sch_DupGroup
Definition SR.cs:530
static string Sch_DupNotation
Definition SR.cs:534
Definition SR.cs:7
readonly XmlNameTable _nameTable
void SendValidationEvent(string code, XmlSchemaObject source)
bool IsValidGroupRedefine(XmlSchemaObject existingObject, XmlSchemaObject item, XmlSchemaObjectTable table)
bool IsValidAttributeGroupRedefine(XmlSchemaObject existingObject, XmlSchemaObject item, XmlSchemaObjectTable table)
bool IsValidTypeRedefine(XmlSchemaObject existingObject, XmlSchemaObject item, XmlSchemaObjectTable table)
string Add(char[] array, int offset, int length)

References System.Xml.Schema.BaseProcessor._nameTable, System.Xml.Schema.BaseProcessor._nsXml, System.Xml.XmlNameTable.Add(), System.Xml.Schema.XmlSchemaObjectTable.Add(), System.Xml.Dictionary, System.Xml.Ref.Equal(), System.Xml.Schema.Preprocessor.GetBuildInSchema(), System.Xml.Schema.XmlSchemaObjectTable.Insert(), System.Xml.Schema.BaseProcessor.IsValidAttributeGroupRedefine(), System.Xml.Schema.BaseProcessor.IsValidGroupRedefine(), System.Xml.Schema.BaseProcessor.IsValidTypeRedefine(), System.item, System.Xml.XmlQualifiedName.Name, System.Xml.XmlQualifiedName.Namespace, System.SR.Sch_DupAttributeGroup, System.SR.Sch_DupComplexType, System.SR.Sch_DupGlobalAttribute, System.SR.Sch_DupGlobalElement, System.SR.Sch_DupGroup, System.SR.Sch_DupIdentityConstraint, System.SR.Sch_DupNotation, System.SR.Sch_DupSimpleType, System.Xml.Schema.BaseProcessor.SendValidationEvent(), and System.Xml.XmlQualifiedName.ToString().

Referenced by System.Xml.Schema.Preprocessor.CopyIncludedComponents(), System.Xml.Schema.Compiler.Prepare(), System.Xml.Schema.Preprocessor.Preprocess(), System.Xml.Schema.SchemaCollectionPreprocessor.Preprocess(), System.Xml.Schema.Preprocessor.PreprocessRedefine(), and System.Xml.Schema.SchemaCollectionPreprocessor.PreprocessRedefine().