예제 #1
0
 public void AddRange(XmlSchemaCompletionCollection schemas)
 {
     for (int i = 0; i < schemas.Count; i++)
     {
         Add(schemas[i]);
     }
 }
예제 #2
0
        XmlSchemaCompletionCollection GetSchemaCollectionUsingDefaultSchema(XmlElementPath path, XmlSchemaCompletion defaultSchema)
        {
            XmlSchemaCompletionCollection schemas = new XmlSchemaCompletionCollection();

            if (defaultSchema != null)
            {
                path.SetNamespaceForUnqualifiedNames(defaultSchema.NamespaceUri);
                schemas.Add(defaultSchema);
            }
            return(schemas);
        }
예제 #3
0
        /*public XmlSchemaCompletion GetSchemaFromFileName(string fileName)
         * {
         *  foreach (XmlSchemaCompletion schema in this)
         *  {
         *      if (FileUtility.IsEqualFileName(schema.FileName, fileName))
         *      {
         *          return schema;
         *      }
         *  }
         *  return null;
         * }*/

        public XmlSchemaCompletionCollection GetSchemas(string namespaceUri)
        {
            XmlSchemaCompletionCollection schemas = new XmlSchemaCompletionCollection();

            foreach (XmlSchemaCompletion schema in this)
            {
                if (schema.NamespaceUri == namespaceUri)
                {
                    schemas.Add(schema);
                }
            }
            return(schemas);
        }
예제 #4
0
 public XmlSchemaCompletionCollection(XmlSchemaCompletionCollection schemas)
 {
     AddRange(schemas);
 }