Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / Xml / System / Xml / schema / XmlSchemaFacet.cs / 1 / 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
- ContainerCodeDomSerializer.cs
- ContentType.cs
- MsmqIntegrationOutputChannel.cs
- IntegerCollectionEditor.cs
- TextContainerChangeEventArgs.cs
- ConfigurationElement.cs
- SHA1Managed.cs
- ToolBarButton.cs
- Pen.cs
- OracleCommand.cs
- FloatMinMaxAggregationOperator.cs
- LinearGradientBrush.cs
- PrimitiveCodeDomSerializer.cs
- TextFormatterContext.cs
- DefinitionBase.cs
- hresults.cs
- EntityTypeEmitter.cs
- OutputCacheSettings.cs
- CategoryValueConverter.cs
- Vertex.cs
- DataContractFormatAttribute.cs
- DbFunctionCommandTree.cs
- SemaphoreSlim.cs
- WorkflowEnvironment.cs
- CodeNamespaceImport.cs
- ByteConverter.cs
- XmlArrayItemAttributes.cs
- InstanceDataCollectionCollection.cs
- TPLETWProvider.cs
- FixedSchema.cs
- RepeaterCommandEventArgs.cs
- MoveSizeWinEventHandler.cs
- VisualTreeUtils.cs
- SafeProcessHandle.cs
- DataGridRelationshipRow.cs
- SafeFileMappingHandle.cs
- DictionaryTraceRecord.cs
- Emitter.cs
- HtmlHead.cs
- DefaultAuthorizationContext.cs
- RuleProcessor.cs
- wmiutil.cs
- GlyphManager.cs
- DynamicExpression.cs
- TablePattern.cs
- CannotUnloadAppDomainException.cs
- HttpContext.cs
- OracleNumber.cs
- QueryCursorEventArgs.cs
- XamlFilter.cs
- SuppressIldasmAttribute.cs
- IndentedTextWriter.cs
- TimeoutException.cs
- XNameConverter.cs
- DataGridViewCellErrorTextNeededEventArgs.cs
- DrawingContext.cs
- EventDrivenDesigner.cs
- GlobalProxySelection.cs
- ReadOnlyCollection.cs
- RegexCaptureCollection.cs
- WeakReferenceKey.cs
- EdmTypeAttribute.cs
- ExceptionValidationRule.cs
- ProcessHostServerConfig.cs
- ModifiableIteratorCollection.cs
- ColorAnimationUsingKeyFrames.cs
- Vector3DValueSerializer.cs
- XPathEmptyIterator.cs
- DesignerSelectionListAdapter.cs
- SqlServer2KCompatibilityCheck.cs
- TableLayoutSettingsTypeConverter.cs
- SafeSecurityHandles.cs
- HttpListenerContext.cs
- XamlDebuggerXmlReader.cs
- TableRow.cs
- RoleService.cs
- WebPartChrome.cs
- XmlWriterSettings.cs
- DefaultValueTypeConverter.cs
- GlobalProxySelection.cs
- XmlArrayAttribute.cs
- ExpandableObjectConverter.cs
- IncrementalReadDecoders.cs
- EdmTypeAttribute.cs
- BamlLocalizationDictionary.cs
- ForEachAction.cs
- XmlParserContext.cs
- ProfileEventArgs.cs
- Monitor.cs
- CachedTypeface.cs
- WebPartDisplayModeCollection.cs
- TimeZoneNotFoundException.cs
- SystemPens.cs
- GridErrorDlg.cs
- SchemaType.cs
- UIElement3D.cs
- RegistrationServices.cs
- FileCodeGroup.cs
- CommandManager.cs
- CachingHintValidation.cs