System.Xml.Schema.XmlSchemaObjectTable.Add C# (CSharp) Method

Add() private method

private Add ( XmlQualifiedName name, XmlSchemaObject value ) : void
name System.Xml.XmlQualifiedName
value XmlSchemaObject
return void
        internal void Add(XmlQualifiedName name,  XmlSchemaObject value) {
            Debug.Assert(!table.ContainsKey(name), "XmlSchemaObjectTable.Add: entry already exists");
            table.Add(name, value);
            entries.Add(new XmlSchemaObjectEntry(name, value));
        }

Usage Example

Example #1
0
 private void AddGlobalComponents(XmlSchema schema)
 {
     foreach (XmlSchemaElement el in schema.Elements.Values)
     {
         GlobalElements.Add(el.QualifiedName, el);
     }
     foreach (XmlSchemaAttribute a in schema.Attributes.Values)
     {
         GlobalAttributes.Add(a.QualifiedName, a);
     }
     foreach (XmlSchemaType t in schema.SchemaTypes.Values)
     {
         GlobalTypes.Add(t.QualifiedName, t);
     }
     foreach (XmlSchemaAttributeGroup g in schema.AttributeGroups.Values)
     {
         global_attribute_groups.Add(g.QualifiedName, g);
     }
     foreach (XmlSchemaGroup g in schema.Groups.Values)
     {
         global_groups.Add(g.QualifiedName, g);
     }
     foreach (DictionaryEntry pair in schema.IDCollection)
     {
         global_ids.Add(pair.Key, pair.Value);
     }
     foreach (XmlSchemaIdentityConstraint ic in schema.NamedIdentities.Values)
     {
         global_identity_constraints.Add(ic.QualifiedName, ic);
     }
 }
All Usage Examples Of System.Xml.Schema.XmlSchemaObjectTable::Add