Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
QNameFacetsChecker.cs
Go to the documentation of this file.
2
3namespace System.Xml.Schema;
4
5internal sealed class QNameFacetsChecker : FacetsChecker
6{
12
14 {
17 if (restrictionFlags != 0)
18 {
19 string text = value.ToString();
20 int length = text.Length;
22 {
24 }
25 if ((restrictionFlags & RestrictionFlags.MinLength) != 0 && length < restriction.MinLength)
26 {
28 }
29 if ((restrictionFlags & RestrictionFlags.MaxLength) != 0 && restriction.MaxLength < length)
30 {
32 }
33 if ((restrictionFlags & RestrictionFlags.Enumeration) != 0 && !MatchEnumeration(value, restriction.Enumeration))
34 {
36 }
37 }
38 return null;
39 }
40
45
47 {
48 for (int i = 0; i < enumeration.Count; i++)
49 {
50 if (value.Equals((XmlQualifiedName)enumeration[i]))
51 {
52 return true;
53 }
54 }
55 return false;
56 }
57}
static string Sch_LengthConstraintFailed
Definition SR.cs:686
static string Sch_MinLengthConstraintFailed
Definition SR.cs:688
static string Sch_EnumerationConstraintFailed
Definition SR.cs:694
static string Sch_MaxLengthConstraintFailed
Definition SR.cs:690
Definition SR.cs:7
bool MatchEnumeration(XmlQualifiedName value, ArrayList enumeration)
override Exception CheckValueFacets(XmlQualifiedName value, XmlSchemaDatatype datatype)
override bool MatchEnumeration(object value, ArrayList enumeration, XmlSchemaDatatype datatype)
override Exception CheckValueFacets(object value, XmlSchemaDatatype datatype)
object ChangeType(bool value, Type destinationType)