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

◆ CompileFacetCombinations()

void System.Xml.Schema.FacetsChecker.FacetsCompiler.CompileFacetCombinations ( )
inlinepackage

Definition at line 375 of file FacetsChecker.cs.

376 {
377 if ((_derivedRestriction.Flags & RestrictionFlags.MaxInclusive) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MaxExclusive) != 0)
378 {
379 throw new XmlSchemaException(System.SR.Sch_MaxInclusiveExclusive, string.Empty);
380 }
381 if ((_derivedRestriction.Flags & RestrictionFlags.MinInclusive) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MinExclusive) != 0)
382 {
383 throw new XmlSchemaException(System.SR.Sch_MinInclusiveExclusive, string.Empty);
384 }
385 if ((_derivedRestriction.Flags & RestrictionFlags.Length) != 0 && (_derivedRestriction.Flags & (RestrictionFlags.MinLength | RestrictionFlags.MaxLength)) != 0)
386 {
387 throw new XmlSchemaException(System.SR.Sch_LengthAndMinMax, string.Empty);
388 }
390 if ((_derivedRestriction.Flags & RestrictionFlags.MinLength) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MaxLength) != 0 && _derivedRestriction.MinLength > _derivedRestriction.MaxLength)
391 {
392 throw new XmlSchemaException(System.SR.Sch_MinLengthGtMaxLength, string.Empty);
393 }
394 if ((_derivedRestriction.Flags & RestrictionFlags.MinInclusive) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MaxInclusive) != 0 && _datatype.Compare(_derivedRestriction.MinInclusive, _derivedRestriction.MaxInclusive) > 0)
395 {
396 throw new XmlSchemaException(System.SR.Sch_MinInclusiveGtMaxInclusive, string.Empty);
397 }
398 if ((_derivedRestriction.Flags & RestrictionFlags.MinInclusive) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MaxExclusive) != 0 && _datatype.Compare(_derivedRestriction.MinInclusive, _derivedRestriction.MaxExclusive) > 0)
399 {
400 throw new XmlSchemaException(System.SR.Sch_MinInclusiveGtMaxExclusive, string.Empty);
401 }
402 if ((_derivedRestriction.Flags & RestrictionFlags.MinExclusive) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MaxExclusive) != 0 && _datatype.Compare(_derivedRestriction.MinExclusive, _derivedRestriction.MaxExclusive) > 0)
403 {
404 throw new XmlSchemaException(System.SR.Sch_MinExclusiveGtMaxExclusive, string.Empty);
405 }
406 if ((_derivedRestriction.Flags & RestrictionFlags.MinExclusive) != 0 && (_derivedRestriction.Flags & RestrictionFlags.MaxInclusive) != 0 && _datatype.Compare(_derivedRestriction.MinExclusive, _derivedRestriction.MaxInclusive) > 0)
407 {
408 throw new XmlSchemaException(System.SR.Sch_MinExclusiveGtMaxInclusive, string.Empty);
409 }
410 if ((_derivedRestriction.Flags & (RestrictionFlags.TotalDigits | RestrictionFlags.FractionDigits)) == (RestrictionFlags.TotalDigits | RestrictionFlags.FractionDigits) && _derivedRestriction.FractionDigits > _derivedRestriction.TotalDigits)
411 {
412 throw new XmlSchemaException(System.SR.Sch_FractionDigitsGtTotalDigits, string.Empty);
413 }
414 }
static string Sch_MinInclusiveExclusive
Definition SR.cs:758
static string Sch_MinExclusiveGtMaxInclusive
Definition SR.cs:766
static string Sch_MinExclusiveGtMaxExclusive
Definition SR.cs:762
static string Sch_MaxInclusiveExclusive
Definition SR.cs:756
static string Sch_MinInclusiveGtMaxInclusive
Definition SR.cs:760
static string Sch_FractionDigitsGtTotalDigits
Definition SR.cs:684
static string Sch_MinInclusiveGtMaxExclusive
Definition SR.cs:764
static string Sch_MinLengthGtMaxLength
Definition SR.cs:682
static string Sch_LengthAndMinMax
Definition SR.cs:680
Definition SR.cs:7
int Compare(byte[] value1, byte[] value2)
readonly RestrictionFacets _derivedRestriction
readonly DatatypeImplementation _datatype

References System.Xml.Schema.FacetsChecker.FacetsCompiler._datatype, System.Xml.Schema.FacetsChecker.FacetsCompiler._derivedRestriction, System.Xml.Schema.DatatypeImplementation.Compare(), System.Xml.Schema.FacetsChecker.FacetsCompiler.CopyFacetsFromBaseType(), System.Xml.Schema.RestrictionFacets.Flags, System.Xml.Schema.RestrictionFacets.FractionDigits, System.Xml.Schema.RestrictionFacets.MaxExclusive, System.Xml.Schema.RestrictionFacets.MaxInclusive, System.Xml.Schema.RestrictionFacets.MaxLength, System.Xml.Schema.RestrictionFacets.MinExclusive, System.Xml.Schema.RestrictionFacets.MinInclusive, System.Xml.Schema.RestrictionFacets.MinLength, System.SR.Sch_FractionDigitsGtTotalDigits, System.SR.Sch_LengthAndMinMax, System.SR.Sch_MaxInclusiveExclusive, System.SR.Sch_MinExclusiveGtMaxExclusive, System.SR.Sch_MinExclusiveGtMaxInclusive, System.SR.Sch_MinInclusiveExclusive, System.SR.Sch_MinInclusiveGtMaxExclusive, System.SR.Sch_MinInclusiveGtMaxInclusive, System.SR.Sch_MinLengthGtMaxLength, and System.Xml.Schema.RestrictionFacets.TotalDigits.