The Labs \ Source Viewer \ SSCLI \ System.Xml.Schema \ XmlSchemaSimpleContentRestriction

  1. //------------------------------------------------------------------------------
  2. // <copyright file="XmlSchemaSimpleContentRestriction.cs" company="Microsoft">
  3. //
  4. // Copyright (c) 2006 Microsoft Corporation. All rights reserved.
  5. //
  6. // The use and distribution terms for this software are contained in the file
  7. // named license.txt, which can be found in the root of this distribution.
  8. // By using this software in any fashion, you are agreeing to be bound by the
  9. // terms of this license.
  10. //
  11. // You must not remove this notice, or any other, from this software.
  12. //
  13. // </copyright>
  14. // <owner current="true" primary="true">priyal</owner>
  15. //------------------------------------------------------------------------------
  16. namespace System.Xml.Schema
  17. {
  18.    
  19.     using System.Xml.Serialization;
  20.    
  21.     /// <include file='doc\XmlSchemaSimpleContentRestriction.uex' path='docs/doc[@for="XmlSchemaSimpleContentRestriction"]/*' />
  22.     /// <devdoc>
  23.     /// <para>[To be supplied.]</para>
  24.     /// </devdoc>
  25.     public class XmlSchemaSimpleContentRestriction : XmlSchemaContent
  26.     {
  27.         XmlQualifiedName baseTypeName = XmlQualifiedName.Empty;
  28.         XmlSchemaSimpleType baseType;
  29.         XmlSchemaObjectCollection facets = new XmlSchemaObjectCollection();
  30.         XmlSchemaObjectCollection attributes = new XmlSchemaObjectCollection();
  31.         XmlSchemaAnyAttribute anyAttribute;
  32.        
  33.         /// <include file='doc\XmlSchemaSimpleContentRestriction.uex' path='docs/doc[@for="XmlSchemaSimpleContentRestriction.BaseTypeName"]/*' />
  34.         /// <devdoc>
  35.         /// <para>[To be supplied.]</para>
  36.         /// </devdoc>
  37.         [XmlAttribute("base")]
  38.         public XmlQualifiedName BaseTypeName {
  39.             get { return baseTypeName; }
  40.             set { baseTypeName = (value == null ? XmlQualifiedName.Empty : value); }
  41.         }
  42.        
  43.         /// <include file='doc\XmlSchemaSimpleContentRestriction.uex' path='docs/doc[@for="XmlSchemaSimpleContentRestriction.BaseType"]/*' />
  44.         /// <devdoc>
  45.         /// <para>[To be supplied.]</para>
  46.         /// </devdoc>
  47.         [XmlElement("simpleType", typeof(XmlSchemaSimpleType))]
  48.         public XmlSchemaSimpleType BaseType {
  49.             get { return baseType; }
  50.             set { baseType = value; }
  51.         }
  52.        
  53.         /// <include file='doc\XmlSchemaSimpleContentRestriction.uex' path='docs/doc[@for="XmlSchemaSimpleContentRestriction.Facets"]/*' />
  54.         /// <devdoc>
  55.         /// <para>[To be supplied.]</para>
  56.         /// </devdoc>
  57.         [XmlElement("length", typeof(XmlSchemaLengthFacet)), XmlElement("minLength", typeof(XmlSchemaMinLengthFacet)), XmlElement("maxLength", typeof(XmlSchemaMaxLengthFacet)), XmlElement("pattern", typeof(XmlSchemaPatternFacet)), XmlElement("enumeration", typeof(XmlSchemaEnumerationFacet)), XmlElement("maxInclusive", typeof(XmlSchemaMaxInclusiveFacet)), XmlElement("maxExclusive", typeof(XmlSchemaMaxExclusiveFacet)), XmlElement("minInclusive", typeof(XmlSchemaMinInclusiveFacet)), XmlElement("minExclusive", typeof(XmlSchemaMinExclusiveFacet)), XmlElement("totalDigits", typeof(XmlSchemaTotalDigitsFacet)), XmlElement("fractionDigits", typeof(XmlSchemaFractionDigitsFacet)), XmlElement("whiteSpace", typeof(XmlSchemaWhiteSpaceFacet))]
  58.         public XmlSchemaObjectCollection Facets {
  59.             get { return facets; }
  60.         }
  61.        
  62.         /// <include file='doc\XmlSchemaSimpleContentRestriction.uex' path='docs/doc[@for="XmlSchemaSimpleContentRestriction.Attributes"]/*' />
  63.         /// <devdoc>
  64.         /// <para>[To be supplied.]</para>
  65.         /// </devdoc>
  66.         [XmlElement("attribute", typeof(XmlSchemaAttribute)), XmlElement("attributeGroup", typeof(XmlSchemaAttributeGroupRef))]
  67.         public XmlSchemaObjectCollection Attributes {
  68.             get { return attributes; }
  69.         }
  70.        
  71.         /// <include file='doc\XmlSchemaSimpleContentRestriction.uex' path='docs/doc[@for="XmlSchemaSimpleContentRestriction.AnyAttribute"]/*' />
  72.         /// <devdoc>
  73.         /// <para>[To be supplied.]</para>
  74.         /// </devdoc>
  75.         [XmlElement("anyAttribute")]
  76.         public XmlSchemaAnyAttribute AnyAttribute {
  77.             get { return anyAttribute; }
  78.             set { anyAttribute = value; }
  79.         }
  80.        
  81.         internal void SetAttributes(XmlSchemaObjectCollection newAttributes)
  82.         {
  83.             attributes = newAttributes;
  84.         }
  85.     }
  86. }

Developer Fusion