Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Xml / System / Xml / schema / XmlSchemaFacet.cs / 1305376 / XmlSchemaFacet.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml.Schema { using System.ComponentModel; using System.Xml.Serialization; internal enum FacetType { None, Length, MinLength, MaxLength, Pattern, Whitespace, Enumeration, MinExclusive, MinInclusive, MaxExclusive, MaxInclusive, TotalDigits, FractionDigits, } ///public abstract class XmlSchemaFacet : XmlSchemaAnnotated { string value; bool isFixed; FacetType facetType; /// [XmlAttribute("value")] public string Value { get { return this.value; } set { this.value = value; } } /// [XmlAttribute("fixed"), DefaultValue(false)] public virtual bool IsFixed { get { return isFixed; } set { if (!(this is XmlSchemaEnumerationFacet) && !(this is XmlSchemaPatternFacet)) { isFixed = value; } } } internal FacetType FacetType { get { return facetType; } set { facetType = value; } } } /// public abstract class XmlSchemaNumericFacet : XmlSchemaFacet { } /// public class XmlSchemaLengthFacet : XmlSchemaNumericFacet { public XmlSchemaLengthFacet() { FacetType = FacetType.Length; } } /// public class XmlSchemaMinLengthFacet : XmlSchemaNumericFacet { public XmlSchemaMinLengthFacet() { FacetType = FacetType.MinLength; } } /// public class XmlSchemaMaxLengthFacet : XmlSchemaNumericFacet { public XmlSchemaMaxLengthFacet() { FacetType = FacetType.MaxLength; } } /// public class XmlSchemaPatternFacet : XmlSchemaFacet { public XmlSchemaPatternFacet() { FacetType = FacetType.Pattern; } } /// public class XmlSchemaEnumerationFacet : XmlSchemaFacet { public XmlSchemaEnumerationFacet() { FacetType = FacetType.Enumeration; } } /// public class XmlSchemaMinExclusiveFacet : XmlSchemaFacet { public XmlSchemaMinExclusiveFacet() { FacetType = FacetType.MinExclusive; } } /// public class XmlSchemaMinInclusiveFacet : XmlSchemaFacet { public XmlSchemaMinInclusiveFacet() { FacetType = FacetType.MinInclusive; } } /// public class XmlSchemaMaxExclusiveFacet : XmlSchemaFacet { public XmlSchemaMaxExclusiveFacet() { FacetType = FacetType.MaxExclusive; } } /// public class XmlSchemaMaxInclusiveFacet : XmlSchemaFacet { public XmlSchemaMaxInclusiveFacet() { FacetType = FacetType.MaxInclusive; } } /// public class XmlSchemaTotalDigitsFacet : XmlSchemaNumericFacet { public XmlSchemaTotalDigitsFacet() { FacetType = FacetType.TotalDigits; } } /// public class XmlSchemaFractionDigitsFacet : XmlSchemaNumericFacet { public XmlSchemaFractionDigitsFacet() { FacetType = FacetType.FractionDigits; } } /// public class XmlSchemaWhiteSpaceFacet : XmlSchemaFacet { public XmlSchemaWhiteSpaceFacet() { FacetType = FacetType.Whitespace; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ // // Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml.Schema { using System.ComponentModel; using System.Xml.Serialization; internal enum FacetType { None, Length, MinLength, MaxLength, Pattern, Whitespace, Enumeration, MinExclusive, MinInclusive, MaxExclusive, MaxInclusive, TotalDigits, FractionDigits, } ///public abstract class XmlSchemaFacet : XmlSchemaAnnotated { string value; bool isFixed; FacetType facetType; /// [XmlAttribute("value")] public string Value { get { return this.value; } set { this.value = value; } } /// [XmlAttribute("fixed"), DefaultValue(false)] public virtual bool IsFixed { get { return isFixed; } set { if (!(this is XmlSchemaEnumerationFacet) && !(this is XmlSchemaPatternFacet)) { isFixed = value; } } } internal FacetType FacetType { get { return facetType; } set { facetType = value; } } } /// public abstract class XmlSchemaNumericFacet : XmlSchemaFacet { } /// public class XmlSchemaLengthFacet : XmlSchemaNumericFacet { public XmlSchemaLengthFacet() { FacetType = FacetType.Length; } } /// public class XmlSchemaMinLengthFacet : XmlSchemaNumericFacet { public XmlSchemaMinLengthFacet() { FacetType = FacetType.MinLength; } } /// public class XmlSchemaMaxLengthFacet : XmlSchemaNumericFacet { public XmlSchemaMaxLengthFacet() { FacetType = FacetType.MaxLength; } } /// public class XmlSchemaPatternFacet : XmlSchemaFacet { public XmlSchemaPatternFacet() { FacetType = FacetType.Pattern; } } /// public class XmlSchemaEnumerationFacet : XmlSchemaFacet { public XmlSchemaEnumerationFacet() { FacetType = FacetType.Enumeration; } } /// public class XmlSchemaMinExclusiveFacet : XmlSchemaFacet { public XmlSchemaMinExclusiveFacet() { FacetType = FacetType.MinExclusive; } } /// public class XmlSchemaMinInclusiveFacet : XmlSchemaFacet { public XmlSchemaMinInclusiveFacet() { FacetType = FacetType.MinInclusive; } } /// public class XmlSchemaMaxExclusiveFacet : XmlSchemaFacet { public XmlSchemaMaxExclusiveFacet() { FacetType = FacetType.MaxExclusive; } } /// public class XmlSchemaMaxInclusiveFacet : XmlSchemaFacet { public XmlSchemaMaxInclusiveFacet() { FacetType = FacetType.MaxInclusive; } } /// public class XmlSchemaTotalDigitsFacet : XmlSchemaNumericFacet { public XmlSchemaTotalDigitsFacet() { FacetType = FacetType.TotalDigits; } } /// public class XmlSchemaFractionDigitsFacet : XmlSchemaNumericFacet { public XmlSchemaFractionDigitsFacet() { FacetType = FacetType.FractionDigits; } } /// public class XmlSchemaWhiteSpaceFacet : XmlSchemaFacet { public XmlSchemaWhiteSpaceFacet() { FacetType = FacetType.Whitespace; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ServiceDescriptions.cs
- DrawingGroupDrawingContext.cs
- ProjectionPathSegment.cs
- SpeakInfo.cs
- HttpValueCollection.cs
- ToggleButtonAutomationPeer.cs
- DoubleIndependentAnimationStorage.cs
- smtppermission.cs
- SqlBulkCopyColumnMappingCollection.cs
- externdll.cs
- PathFigureCollection.cs
- RowType.cs
- WorkflowWebHostingModule.cs
- HtmlFormAdapter.cs
- DependencyPropertyChangedEventArgs.cs
- InstanceNotFoundException.cs
- SvcMapFile.cs
- TextServicesCompartment.cs
- SchemeSettingElementCollection.cs
- ConfigXmlSignificantWhitespace.cs
- ScrollProviderWrapper.cs
- TextElementEnumerator.cs
- TripleDESCryptoServiceProvider.cs
- ICspAsymmetricAlgorithm.cs
- Int32Converter.cs
- RuleSetDialog.Designer.cs
- MethodImplAttribute.cs
- ContainerFilterService.cs
- Exceptions.cs
- TableAdapterManagerHelper.cs
- TdsParserStaticMethods.cs
- CodeDOMProvider.cs
- TypeCacheManager.cs
- SimpleFieldTemplateUserControl.cs
- ActiveXHost.cs
- _DomainName.cs
- StringInfo.cs
- SchemaEntity.cs
- RequestUriProcessor.cs
- TextEditor.cs
- Tile.cs
- XmlToDatasetMap.cs
- BaseUriWithWildcard.cs
- Floater.cs
- FormatterServices.cs
- FileRecordSequenceCompletedAsyncResult.cs
- ListViewDesigner.cs
- TableHeaderCell.cs
- IssuanceTokenProviderState.cs
- WebPartDescriptionCollection.cs
- PointConverter.cs
- Section.cs
- RoleService.cs
- DataSourceCacheDurationConverter.cs
- FixedSOMPage.cs
- DtdParser.cs
- _NestedMultipleAsyncResult.cs
- Style.cs
- XamlWriter.cs
- ResizeGrip.cs
- ToolStripItemTextRenderEventArgs.cs
- TempFiles.cs
- ServiceSecurityContext.cs
- ProcessThread.cs
- AuthenticationException.cs
- RequestCacheValidator.cs
- IisTraceListener.cs
- SourceChangedEventArgs.cs
- TextDecorationCollectionConverter.cs
- Condition.cs
- ObjectCacheHost.cs
- DataGridRowHeader.cs
- CompilerParameters.cs
- NavigationWindowAutomationPeer.cs
- WebPartConnectionsDisconnectVerb.cs
- Subset.cs
- TranslateTransform3D.cs
- LocalServiceSecuritySettingsElement.cs
- WebControl.cs
- ReflectionPermission.cs
- XmlSchemaProviderAttribute.cs
- SaveFileDialog.cs
- HtmlAnchor.cs
- XmlSchemaAll.cs
- TextMetrics.cs
- FamilyTypeface.cs
- AssemblyAttributes.cs
- HierarchicalDataSourceControl.cs
- APCustomTypeDescriptor.cs
- RemoteDebugger.cs
- WebServiceHostFactory.cs
- _StreamFramer.cs
- ConfigurationLocation.cs
- CounterCreationDataCollection.cs
- Deflater.cs
- HtmlUtf8RawTextWriter.cs
- ReferenceAssemblyAttribute.cs
- WeakHashtable.cs
- FloatUtil.cs
- XmlSchemaComplexContentExtension.cs