299 references to RestrictionFlags
System.Private.Xml (299)
System\Xml\Schema\DataTypeImplementation.cs (120)
93
internal
RestrictionFlags
Flags;
94
internal
RestrictionFlags
FixedFlags;
502
RestrictionFlags
flags = _restriction != null ? _restriction.Flags : 0;
503
if (flags != 0 && (flags & (
RestrictionFlags
.Pattern |
RestrictionFlags
.WhiteSpace |
RestrictionFlags
.TotalDigits |
RestrictionFlags
.FractionDigits)) != 0)
514
RestrictionFlags
flags = _restriction != null ? _restriction.Flags : 0;
515
if (flags != 0 && (flags & (
RestrictionFlags
.Length |
RestrictionFlags
.MinLength |
RestrictionFlags
.MaxLength |
RestrictionFlags
.MaxExclusive |
RestrictionFlags
.MaxInclusive |
RestrictionFlags
.MinExclusive |
RestrictionFlags
.MinInclusive |
RestrictionFlags
.TotalDigits |
RestrictionFlags
.FractionDigits |
RestrictionFlags
.Enumeration)) != 0)
525
internal abstract
RestrictionFlags
ValidRestrictionFlags { get; }
1005
internal override
RestrictionFlags
ValidRestrictionFlags
1009
return
RestrictionFlags
.Length |
RestrictionFlags
.MinLength |
RestrictionFlags
.MaxLength |
RestrictionFlags
.Enumeration |
RestrictionFlags
.WhiteSpace |
RestrictionFlags
.Pattern;
1197
internal override
RestrictionFlags
ValidRestrictionFlags
1201
return
RestrictionFlags
.Pattern |
1202
RestrictionFlags
.Enumeration;
1365
internal override
RestrictionFlags
ValidRestrictionFlags { get { return 0; } }
1443
internal override
RestrictionFlags
ValidRestrictionFlags
1447
return
RestrictionFlags
.Length |
1448
RestrictionFlags
.MinLength |
1449
RestrictionFlags
.MaxLength |
1450
RestrictionFlags
.Pattern |
1451
RestrictionFlags
.Enumeration |
1452
RestrictionFlags
.WhiteSpace;
1513
internal override
RestrictionFlags
ValidRestrictionFlags
1517
return
RestrictionFlags
.Pattern |
1518
RestrictionFlags
.WhiteSpace;
1590
internal override
RestrictionFlags
ValidRestrictionFlags
1594
return
RestrictionFlags
.Pattern |
1595
RestrictionFlags
.Enumeration |
1596
RestrictionFlags
.WhiteSpace |
1597
RestrictionFlags
.MinExclusive |
1598
RestrictionFlags
.MinInclusive |
1599
RestrictionFlags
.MaxExclusive |
1600
RestrictionFlags
.MaxInclusive;
1676
internal override
RestrictionFlags
ValidRestrictionFlags
1680
return
RestrictionFlags
.Pattern |
1681
RestrictionFlags
.Enumeration |
1682
RestrictionFlags
.WhiteSpace |
1683
RestrictionFlags
.MinExclusive |
1684
RestrictionFlags
.MinInclusive |
1685
RestrictionFlags
.MaxExclusive |
1686
RestrictionFlags
.MaxInclusive;
1766
internal override
RestrictionFlags
ValidRestrictionFlags
1770
return
RestrictionFlags
.TotalDigits |
1771
RestrictionFlags
.FractionDigits |
1772
RestrictionFlags
.Pattern |
1773
RestrictionFlags
.Enumeration |
1774
RestrictionFlags
.WhiteSpace |
1775
RestrictionFlags
.MinExclusive |
1776
RestrictionFlags
.MinInclusive |
1777
RestrictionFlags
.MaxExclusive |
1778
RestrictionFlags
.MaxInclusive;
1855
internal override
RestrictionFlags
ValidRestrictionFlags
1859
return
RestrictionFlags
.Pattern |
1860
RestrictionFlags
.Enumeration |
1861
RestrictionFlags
.WhiteSpace |
1862
RestrictionFlags
.MinExclusive |
1863
RestrictionFlags
.MinInclusive |
1864
RestrictionFlags
.MaxExclusive |
1865
RestrictionFlags
.MaxInclusive;
2004
internal override
RestrictionFlags
ValidRestrictionFlags
2008
return
RestrictionFlags
.Pattern |
2009
RestrictionFlags
.Enumeration |
2010
RestrictionFlags
.WhiteSpace |
2011
RestrictionFlags
.MinExclusive |
2012
RestrictionFlags
.MinInclusive |
2013
RestrictionFlags
.MaxExclusive |
2014
RestrictionFlags
.MaxInclusive;
2394
internal override
RestrictionFlags
ValidRestrictionFlags
2398
return
RestrictionFlags
.Length |
2399
RestrictionFlags
.MinLength |
2400
RestrictionFlags
.MaxLength |
2401
RestrictionFlags
.Pattern |
2402
RestrictionFlags
.Enumeration |
2403
RestrictionFlags
.WhiteSpace;
2492
internal override
RestrictionFlags
ValidRestrictionFlags
2496
return
RestrictionFlags
.Length |
2497
RestrictionFlags
.MinLength |
2498
RestrictionFlags
.MaxLength |
2499
RestrictionFlags
.Pattern |
2500
RestrictionFlags
.Enumeration |
2501
RestrictionFlags
.WhiteSpace;
2596
internal override
RestrictionFlags
ValidRestrictionFlags
2600
return
RestrictionFlags
.Length |
2601
RestrictionFlags
.MinLength |
2602
RestrictionFlags
.MaxLength |
2603
RestrictionFlags
.Pattern |
2604
RestrictionFlags
.Enumeration |
2605
RestrictionFlags
.WhiteSpace;
2680
internal override
RestrictionFlags
ValidRestrictionFlags
2684
return
RestrictionFlags
.Length |
2685
RestrictionFlags
.MinLength |
2686
RestrictionFlags
.MaxLength |
2687
RestrictionFlags
.Pattern |
2688
RestrictionFlags
.Enumeration |
2689
RestrictionFlags
.WhiteSpace;
3013
internal override
RestrictionFlags
ValidRestrictionFlags
3017
return
RestrictionFlags
.Length |
3018
RestrictionFlags
.MinLength |
3019
RestrictionFlags
.MaxLength |
3020
RestrictionFlags
.Pattern |
3021
RestrictionFlags
.Enumeration |
3022
RestrictionFlags
.WhiteSpace;
3080
if (dt.Restriction != null && (dt.Restriction.Flags &
RestrictionFlags
.Enumeration) != 0)
3773
internal override
RestrictionFlags
ValidRestrictionFlags { get { return 0; } } //XDR only
3870
internal override
RestrictionFlags
ValidRestrictionFlags { get { return 0; } }
System\Xml\Schema\FacetChecker.cs (179)
25
private readonly
RestrictionFlags
_baseFlags;
26
private readonly
RestrictionFlags
_baseFixedFlags;
27
private readonly
RestrictionFlags
_validRestrictionFlags;
55
CheckProhibitedFlag(facet,
RestrictionFlags
.Length, SR.Sch_LengthFacetProhibited);
56
CheckDupFlag(facet,
RestrictionFlags
.Length, SR.Sch_DupLengthFacet);
59
if ((_baseFixedFlags &
RestrictionFlags
.Length) != 0)
66
if ((_baseFlags &
RestrictionFlags
.Length) != 0)
74
if ((_baseFlags &
RestrictionFlags
.MinLength) != 0)
82
if ((_baseFlags &
RestrictionFlags
.MaxLength) != 0)
89
SetFlag(facet,
RestrictionFlags
.Length);
94
CheckProhibitedFlag(facet,
RestrictionFlags
.MinLength, SR.Sch_MinLengthFacetProhibited);
95
CheckDupFlag(facet,
RestrictionFlags
.MinLength, SR.Sch_DupMinLengthFacet);
98
if ((_baseFixedFlags &
RestrictionFlags
.MinLength) != 0)
105
if ((_baseFlags &
RestrictionFlags
.MinLength) != 0)
112
if ((_baseFlags &
RestrictionFlags
.Length) != 0)
119
SetFlag(facet,
RestrictionFlags
.MinLength);
124
CheckProhibitedFlag(facet,
RestrictionFlags
.MaxLength, SR.Sch_MaxLengthFacetProhibited);
125
CheckDupFlag(facet,
RestrictionFlags
.MaxLength, SR.Sch_DupMaxLengthFacet);
128
if ((_baseFixedFlags &
RestrictionFlags
.MaxLength) != 0)
135
if ((_baseFlags &
RestrictionFlags
.MaxLength) != 0)
142
if ((_baseFlags &
RestrictionFlags
.Length) != 0)
149
SetFlag(facet,
RestrictionFlags
.MaxLength);
154
CheckProhibitedFlag(facet,
RestrictionFlags
.Pattern, SR.Sch_PatternFacetProhibited);
168
SetFlag(facet,
RestrictionFlags
.Pattern);
173
CheckProhibitedFlag(facet,
RestrictionFlags
.Enumeration, SR.Sch_EnumerationFacetProhibited);
176
SetFlag(facet,
RestrictionFlags
.Enumeration);
181
CheckProhibitedFlag(facet,
RestrictionFlags
.WhiteSpace, SR.Sch_WhiteSpaceFacetProhibited);
182
CheckDupFlag(facet,
RestrictionFlags
.WhiteSpace, SR.Sch_DupWhiteSpaceFacet);
199
if ((_baseFixedFlags &
RestrictionFlags
.WhiteSpace) != 0)
208
if ((_baseFlags &
RestrictionFlags
.WhiteSpace) != 0)
228
SetFlag(facet,
RestrictionFlags
.WhiteSpace);
233
CheckProhibitedFlag(facet,
RestrictionFlags
.MaxInclusive, SR.Sch_MaxInclusiveFacetProhibited);
234
CheckDupFlag(facet,
RestrictionFlags
.MaxInclusive, SR.Sch_DupMaxInclusiveFacet);
237
if ((_baseFixedFlags &
RestrictionFlags
.MaxInclusive) != 0)
245
SetFlag(facet,
RestrictionFlags
.MaxInclusive);
250
CheckProhibitedFlag(facet,
RestrictionFlags
.MaxExclusive, SR.Sch_MaxExclusiveFacetProhibited);
251
CheckDupFlag(facet,
RestrictionFlags
.MaxExclusive, SR.Sch_DupMaxExclusiveFacet);
254
if ((_baseFixedFlags &
RestrictionFlags
.MaxExclusive) != 0)
262
SetFlag(facet,
RestrictionFlags
.MaxExclusive);
267
CheckProhibitedFlag(facet,
RestrictionFlags
.MinInclusive, SR.Sch_MinInclusiveFacetProhibited);
268
CheckDupFlag(facet,
RestrictionFlags
.MinInclusive, SR.Sch_DupMinInclusiveFacet);
271
if ((_baseFixedFlags &
RestrictionFlags
.MinInclusive) != 0)
279
SetFlag(facet,
RestrictionFlags
.MinInclusive);
284
CheckProhibitedFlag(facet,
RestrictionFlags
.MinExclusive, SR.Sch_MinExclusiveFacetProhibited);
285
CheckDupFlag(facet,
RestrictionFlags
.MinExclusive, SR.Sch_DupMinExclusiveFacet);
288
if ((_baseFixedFlags &
RestrictionFlags
.MinExclusive) != 0)
296
SetFlag(facet,
RestrictionFlags
.MinExclusive);
301
CheckProhibitedFlag(facet,
RestrictionFlags
.TotalDigits, SR.Sch_TotalDigitsFacetProhibited);
302
CheckDupFlag(facet,
RestrictionFlags
.TotalDigits, SR.Sch_DupTotalDigitsFacet);
306
if ((_baseFixedFlags &
RestrictionFlags
.TotalDigits) != 0)
313
if ((_baseFlags &
RestrictionFlags
.TotalDigits) != 0)
320
SetFlag(facet,
RestrictionFlags
.TotalDigits);
325
CheckProhibitedFlag(facet,
RestrictionFlags
.FractionDigits, SR.Sch_FractionDigitsFacetProhibited);
326
CheckDupFlag(facet,
RestrictionFlags
.FractionDigits, SR.Sch_DupFractionDigitsFacet);
333
if ((_baseFixedFlags &
RestrictionFlags
.FractionDigits) != 0)
340
if ((_baseFlags &
RestrictionFlags
.FractionDigits) != 0)
347
SetFlag(facet,
RestrictionFlags
.FractionDigits);
382
if ((_baseFlags &
RestrictionFlags
.MaxInclusive) != 0)
389
if ((_baseFlags &
RestrictionFlags
.MaxExclusive) != 0)
399
if ((_baseFlags &
RestrictionFlags
.MaxExclusive) != 0)
406
if ((_baseFlags &
RestrictionFlags
.MaxInclusive) != 0)
416
if ((_baseFlags &
RestrictionFlags
.MinInclusive) != 0)
423
if ((_baseFlags &
RestrictionFlags
.MinExclusive) != 0)
430
if ((_baseFlags &
RestrictionFlags
.MaxExclusive) != 0)
440
if ((_baseFlags &
RestrictionFlags
.MinExclusive) != 0)
447
if ((_baseFlags &
RestrictionFlags
.MinInclusive) != 0)
454
if ((_baseFlags &
RestrictionFlags
.MaxExclusive) != 0)
473
(_derivedRestriction.Flags &
RestrictionFlags
.MaxInclusive) != 0 &&
474
(_derivedRestriction.Flags &
RestrictionFlags
.MaxExclusive) != 0
480
(_derivedRestriction.Flags &
RestrictionFlags
.MinInclusive) != 0 &&
481
(_derivedRestriction.Flags &
RestrictionFlags
.MinExclusive) != 0
487
(_derivedRestriction.Flags &
RestrictionFlags
.Length) != 0 &&
488
(_derivedRestriction.Flags & (
RestrictionFlags
.MinLength |
RestrictionFlags
.MaxLength)) != 0
498
(_derivedRestriction.Flags &
RestrictionFlags
.MinLength) != 0 &&
499
(_derivedRestriction.Flags &
RestrictionFlags
.MaxLength) != 0
509
(_derivedRestriction.Flags &
RestrictionFlags
.MinInclusive) != 0 &&
510
(_derivedRestriction.Flags &
RestrictionFlags
.MaxInclusive) != 0
519
(_derivedRestriction.Flags &
RestrictionFlags
.MinInclusive) != 0 &&
520
(_derivedRestriction.Flags &
RestrictionFlags
.MaxExclusive) != 0
529
(_derivedRestriction.Flags &
RestrictionFlags
.MinExclusive) != 0 &&
530
(_derivedRestriction.Flags &
RestrictionFlags
.MaxExclusive) != 0
539
(_derivedRestriction.Flags &
RestrictionFlags
.MinExclusive) != 0 &&
540
(_derivedRestriction.Flags &
RestrictionFlags
.MaxInclusive) != 0
548
if ((_derivedRestriction.Flags & (
RestrictionFlags
.TotalDigits |
RestrictionFlags
.FractionDigits)) == (
RestrictionFlags
.TotalDigits |
RestrictionFlags
.FractionDigits))
562
(_derivedRestriction.Flags &
RestrictionFlags
.Length) == 0 &&
563
(_baseFlags &
RestrictionFlags
.Length) != 0
567
SetFlag(
RestrictionFlags
.Length);
570
(_derivedRestriction.Flags &
RestrictionFlags
.MinLength) == 0 &&
571
(_baseFlags &
RestrictionFlags
.MinLength) != 0
575
SetFlag(
RestrictionFlags
.MinLength);
578
(_derivedRestriction.Flags &
RestrictionFlags
.MaxLength) == 0 &&
579
(_baseFlags &
RestrictionFlags
.MaxLength) != 0
583
SetFlag(
RestrictionFlags
.MaxLength);
585
if ((_baseFlags &
RestrictionFlags
.Pattern) != 0)
596
SetFlag(
RestrictionFlags
.Pattern);
599
if ((_baseFlags &
RestrictionFlags
.Enumeration) != 0)
602
SetFlag(
RestrictionFlags
.Enumeration);
606
(_derivedRestriction.Flags &
RestrictionFlags
.WhiteSpace) == 0 &&
607
(_baseFlags &
RestrictionFlags
.WhiteSpace) != 0
611
SetFlag(
RestrictionFlags
.WhiteSpace);
614
(_derivedRestriction.Flags &
RestrictionFlags
.MaxInclusive) == 0 &&
615
(_baseFlags &
RestrictionFlags
.MaxInclusive) != 0
619
SetFlag(
RestrictionFlags
.MaxInclusive);
622
(_derivedRestriction.Flags &
RestrictionFlags
.MaxExclusive) == 0 &&
623
(_baseFlags &
RestrictionFlags
.MaxExclusive) != 0
627
SetFlag(
RestrictionFlags
.MaxExclusive);
630
(_derivedRestriction.Flags &
RestrictionFlags
.MinInclusive) == 0 &&
631
(_baseFlags &
RestrictionFlags
.MinInclusive) != 0
635
SetFlag(
RestrictionFlags
.MinInclusive);
638
(_derivedRestriction.Flags &
RestrictionFlags
.MinExclusive) == 0 &&
639
(_baseFlags &
RestrictionFlags
.MinExclusive) != 0
643
SetFlag(
RestrictionFlags
.MinExclusive);
646
(_derivedRestriction.Flags &
RestrictionFlags
.TotalDigits) == 0 &&
647
(_baseFlags &
RestrictionFlags
.TotalDigits) != 0
651
SetFlag(
RestrictionFlags
.TotalDigits);
654
(_derivedRestriction.Flags &
RestrictionFlags
.FractionDigits) == 0 &&
655
(_baseFlags &
RestrictionFlags
.FractionDigits) != 0
659
SetFlag(
RestrictionFlags
.FractionDigits);
742
private void CheckProhibitedFlag(XmlSchemaFacet facet,
RestrictionFlags
flag, string errorCode)
750
private void CheckDupFlag(XmlSchemaFacet facet,
RestrictionFlags
flag, string errorCode)
758
private void SetFlag(XmlSchemaFacet facet,
RestrictionFlags
flag)
767
private void SetFlag(
RestrictionFlags
flag)
851
else if (restriction != null && (restriction.Flags &
RestrictionFlags
.WhiteSpace) != 0)
870
if (restriction != null && (restriction.Flags &
RestrictionFlags
.Pattern) != 0)
1006
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1018
if ((flags &
RestrictionFlags
.MaxInclusive) != 0)
1026
if ((flags &
RestrictionFlags
.MaxExclusive) != 0)
1034
if ((flags &
RestrictionFlags
.MinInclusive) != 0)
1042
if ((flags &
RestrictionFlags
.MinExclusive) != 0)
1049
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1056
return CheckTotalAndFractionDigits(value, restriction.TotalDigits, restriction.FractionDigits, ((flags &
RestrictionFlags
.TotalDigits) != 0), ((flags &
RestrictionFlags
.FractionDigits) != 0));
1131
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1134
if ((flags &
RestrictionFlags
.MaxInclusive) != 0)
1141
if ((flags &
RestrictionFlags
.MaxExclusive) != 0)
1149
if ((flags &
RestrictionFlags
.MinInclusive) != 0)
1157
if ((flags &
RestrictionFlags
.MinExclusive) != 0)
1164
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1207
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1209
if ((flags &
RestrictionFlags
.MaxInclusive) != 0)
1217
if ((flags &
RestrictionFlags
.MaxExclusive) != 0)
1225
if ((flags &
RestrictionFlags
.MinInclusive) != 0)
1233
if ((flags &
RestrictionFlags
.MinExclusive) != 0)
1240
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1278
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1280
if ((flags &
RestrictionFlags
.MaxInclusive) != 0)
1288
if ((flags &
RestrictionFlags
.MaxExclusive) != 0)
1296
if ((flags &
RestrictionFlags
.MinInclusive) != 0)
1304
if ((flags &
RestrictionFlags
.MinExclusive) != 0)
1312
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1363
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1371
if ((flags &
RestrictionFlags
.Length) != 0)
1378
if ((flags &
RestrictionFlags
.MinLength) != 0)
1385
if ((flags &
RestrictionFlags
.MaxLength) != 0)
1392
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1497
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1505
if ((flags &
RestrictionFlags
.Length) != 0)
1512
if ((flags &
RestrictionFlags
.MinLength) != 0)
1519
if ((flags &
RestrictionFlags
.MaxLength) != 0)
1526
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1571
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1574
if ((flags &
RestrictionFlags
.Length) != 0)
1581
if ((flags &
RestrictionFlags
.MinLength) != 0)
1588
if ((flags &
RestrictionFlags
.MaxLength) != 0)
1595
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1632
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1634
if ((flags & (
RestrictionFlags
.Length |
RestrictionFlags
.MinLength |
RestrictionFlags
.MaxLength)) != 0)
1637
if ((flags &
RestrictionFlags
.Length) != 0)
1645
if ((flags &
RestrictionFlags
.MinLength) != 0)
1653
if ((flags &
RestrictionFlags
.MaxLength) != 0)
1661
if ((flags &
RestrictionFlags
.Enumeration) != 0)
1704
RestrictionFlags
flags = restriction != null ? restriction.Flags : 0;
1706
if ((flags &
RestrictionFlags
.Enumeration) != 0)