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

◆ CountGroupSelfReference()

int System.Xml.Schema.Preprocessor.CountGroupSelfReference ( XmlSchemaObjectCollection items,
XmlQualifiedName name,
XmlSchemaGroup redefined )
inlineprivate

Definition at line 915 of file Preprocessor.cs.

916 {
917 int num = 0;
918 for (int i = 0; i < items.Count; i++)
919 {
920 if (items[i] is XmlSchemaGroupRef xmlSchemaGroupRef)
921 {
922 if (xmlSchemaGroupRef.RefName == name)
923 {
925 if (xmlSchemaGroupRef.MinOccurs != 1m || xmlSchemaGroupRef.MaxOccurs != 1m)
926 {
928 }
929 num++;
930 }
931 }
932 else if (items[i] is XmlSchemaGroupBase)
933 {
934 num += CountGroupSelfReference(((XmlSchemaGroupBase)items[i]).Items, name, redefined);
935 }
936 if (num > 1)
937 {
938 break;
939 }
940 }
941 return num;
942 }
static string Sch_MinMaxGroupRedefine
Definition SR.cs:824
Definition SR.cs:7
void SendValidationEvent(string code, XmlSchemaObject source)
int CountGroupSelfReference(XmlSchemaObjectCollection items, XmlQualifiedName name, XmlSchemaGroup redefined)

References System.Collections.CollectionBase.Count, System.Xml.Schema.Preprocessor.CountGroupSelfReference(), System.Xml.Dictionary, System.SR.Sch_MinMaxGroupRedefine, and System.Xml.Schema.BaseProcessor.SendValidationEvent().

Referenced by System.Xml.Schema.Preprocessor.CheckRefinedGroup(), and System.Xml.Schema.Preprocessor.CountGroupSelfReference().