1 //------------------------------------------------------------------------------
2 // <copyright file="XmlSchemaAttributeGroup.cs" company="Microsoft">
3 // Copyright (c) Microsoft Corporation. All rights reserved.
5 // <owner current="true" primary="true">Microsoft</owner>
6 //------------------------------------------------------------------------------
8 namespace System.Xml.Schema {
10 using System.Collections;
11 using System.Xml.Serialization;
13 /// <include file='doc\XmlSchemaAttributeGroup.uex' path='docs/doc[@for="XmlSchemaAttributeGroup"]/*' />
15 /// <para>[To be supplied.]</para>
17 public class XmlSchemaAttributeGroup : XmlSchemaAnnotated {
19 XmlSchemaObjectCollection attributes = new XmlSchemaObjectCollection();
20 XmlSchemaAnyAttribute anyAttribute;
21 XmlQualifiedName qname = XmlQualifiedName.Empty;
22 XmlSchemaAttributeGroup redefined;
23 XmlSchemaObjectTable attributeUses;
24 XmlSchemaAnyAttribute attributeWildcard;
25 int selfReferenceCount;
27 /// <include file='doc\XmlSchemaAttributeGroup.uex' path='docs/doc[@for="XmlSchemaAttributeGroup.Name"]/*' />
29 /// <para>[To be supplied.]</para>
31 [XmlAttribute("name")]
37 /// <include file='doc\XmlSchemaAttributeGroup.uex' path='docs/doc[@for="XmlSchemaAttributeGroup.Attributes"]/*' />
39 /// <para>[To be supplied.]</para>
41 [XmlElement("attribute", typeof(XmlSchemaAttribute)),
42 XmlElement("attributeGroup", typeof(XmlSchemaAttributeGroupRef))]
43 public XmlSchemaObjectCollection Attributes {
44 get { return attributes; }
47 /// <include file='doc\XmlSchemaAttributeGroup.uex' path='docs/doc[@for="XmlSchemaAttributeGroup.AnyAttribute"]/*' />
49 /// <para>[To be supplied.]</para>
51 [XmlElement("anyAttribute")]
52 public XmlSchemaAnyAttribute AnyAttribute {
53 get { return anyAttribute; }
54 set { anyAttribute = value; }
58 public XmlQualifiedName QualifiedName {
63 internal XmlSchemaObjectTable AttributeUses {
65 if (attributeUses == null) {
66 attributeUses = new XmlSchemaObjectTable();
73 internal XmlSchemaAnyAttribute AttributeWildcard {
74 get { return attributeWildcard; }
75 set { attributeWildcard = value; }
78 /// <include file='doc\XmlSchemaAttributeGroup.uex' path='docs/doc[@for="XmlSchemaAttributeGroup.RedefinedAttributeGroup"]/*' />
80 public XmlSchemaAttributeGroup RedefinedAttributeGroup {
81 get { return redefined; }
85 internal XmlSchemaAttributeGroup Redefined {
86 get { return redefined; }
87 set { redefined = value; }
91 internal int SelfReferenceCount {
92 get { return selfReferenceCount; }
93 set { selfReferenceCount = value; }
97 internal override string NameAttribute {
102 internal void SetQualifiedName(XmlQualifiedName value) {
106 internal override XmlSchemaObject Clone() {
107 XmlSchemaAttributeGroup newGroup = (XmlSchemaAttributeGroup)MemberwiseClone();
108 if (XmlSchemaComplexType.HasAttributeQNameRef(this.attributes)) { //If a ref/type name is present
109 newGroup.attributes = XmlSchemaComplexType.CloneAttributes(this.attributes);
111 //Clear compiled tables
112 newGroup.attributeUses = null;