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

◆ CompileComplexContentExtension()

void System.Xml.Schema.SchemaCollectionCompiler.CompileComplexContentExtension ( XmlSchemaComplexType complexType,
XmlSchemaComplexContent complexContent,
XmlSchemaComplexContentExtension complexExtension )
inlineprivate

Definition at line 854 of file SchemaCollectionCompiler.cs.

855 {
856 XmlSchemaComplexType xmlSchemaComplexType = null;
857 if (complexType.Redefined != null && complexExtension.BaseTypeName == complexType.Redefined.QualifiedName)
858 {
859 xmlSchemaComplexType = (XmlSchemaComplexType)complexType.Redefined;
861 }
862 else
863 {
865 if (xmlSchemaComplexType == null)
866 {
868 return;
869 }
870 }
871 if (xmlSchemaComplexType != null && xmlSchemaComplexType.ElementDecl != null && xmlSchemaComplexType.ContentType == XmlSchemaContentType.TextOnly)
872 {
874 return;
875 }
876 complexType.SetBaseSchemaType(xmlSchemaComplexType);
877 if ((xmlSchemaComplexType.FinalResolved & XmlSchemaDerivationMethod.Extension) != 0)
878 {
880 }
881 CompileLocalAttributes(xmlSchemaComplexType, complexType, complexExtension.Attributes, complexExtension.AnyAttribute, XmlSchemaDerivationMethod.Extension);
882 XmlSchemaParticle contentTypeParticle = xmlSchemaComplexType.ContentTypeParticle;
883 XmlSchemaParticle xmlSchemaParticle = CannonicalizeParticle(complexExtension.Particle, root: true, substitution: true);
884 if (contentTypeParticle != XmlSchemaParticle.Empty)
885 {
886 if (xmlSchemaParticle != XmlSchemaParticle.Empty)
887 {
888 XmlSchemaSequence xmlSchemaSequence = new XmlSchemaSequence();
892 }
893 else
894 {
895 complexType.SetContentTypeParticle(contentTypeParticle);
896 }
898 if (xmlSchemaContentType == XmlSchemaContentType.Empty)
899 {
901 }
902 complexType.SetContentType(xmlSchemaContentType);
903 if (complexType.ContentType != xmlSchemaComplexType.ContentType)
904 {
906 }
907 }
908 else
909 {
910 complexType.SetContentTypeParticle(xmlSchemaParticle);
911 complexType.SetContentType(GetSchemaContentType(complexType, complexContent, complexType.ContentTypeParticle));
912 }
913 complexType.SetDerivedBy(XmlSchemaDerivationMethod.Extension);
914 }
void Add(TKey key, TValue value)
static string Sch_DifContentType
Definition SR.cs:976
static string Sch_NotComplexContent
Definition SR.cs:964
static string Sch_BaseFinalExtension
Definition SR.cs:960
static string Sch_UndefBaseExtension
Definition SR.cs:974
Definition SR.cs:7
void SendValidationEvent(string code, XmlSchemaObject source)
void CompileLocalAttributes(XmlSchemaComplexType baseType, XmlSchemaComplexType derivedType, XmlSchemaObjectCollection attributes, XmlSchemaAnyAttribute anyAttribute, XmlSchemaDerivationMethod derivedBy)
XmlSchemaParticle CannonicalizeParticle(XmlSchemaParticle particle, bool root, bool substitution)
XmlSchemaComplexType GetComplexType(XmlQualifiedName name)
XmlSchemaParticle CompileContentTypeParticle(XmlSchemaParticle particle, bool substitution)
void CompileComplexType(XmlSchemaComplexType complexType)
XmlSchemaContentType GetSchemaContentType(XmlSchemaComplexType complexType, XmlSchemaComplexContent complexContent, XmlSchemaParticle particle)

References System.Collections.Generic.Dictionary< TKey, TValue >.Add(), System.Xml.Schema.SchemaCollectionCompiler.CannonicalizeParticle(), System.Xml.Schema.SchemaCollectionCompiler.CompileComplexType(), System.Xml.Schema.SchemaCollectionCompiler.CompileContentTypeParticle(), System.Xml.Schema.SchemaCollectionCompiler.CompileLocalAttributes(), System.Xml.Dictionary, System.Xml.Schema.XmlSchemaParticle.Empty, System.Xml.Schema.SchemaCollectionCompiler.GetComplexType(), System.Xml.Schema.SchemaCollectionCompiler.GetSchemaContentType(), System.SR.Sch_BaseFinalExtension, System.SR.Sch_DifContentType, System.SR.Sch_NotComplexContent, System.SR.Sch_UndefBaseExtension, and System.Xml.Schema.BaseProcessor.SendValidationEvent().

Referenced by System.Xml.Schema.SchemaCollectionCompiler.CompileComplexType().