コード例 #1
0
 internal static XmlSchemaType GetSchemaType(SchemaObjectDictionary schemaInfo, XmlQualifiedName typeName)
 {
     if (schemaInfo.TryGetValue(typeName, out SchemaObjectInfo schemaObjectInfo))
     {
         return(schemaObjectInfo.type);
     }
     return(null);
 }
コード例 #2
0
 internal static XmlSchemaElement GetSchemaElement(SchemaObjectDictionary schemaInfo, XmlQualifiedName elementName)
 {
     if (schemaInfo.TryGetValue(elementName, out SchemaObjectInfo schemaObjectInfo))
     {
         return(schemaObjectInfo.element);
     }
     return(null);
 }
コード例 #3
0
ファイル: SchemaHelper.cs プロジェクト: dotnet/corefx
 internal static XmlSchemaType GetSchemaType(SchemaObjectDictionary schemaInfo, XmlQualifiedName typeName)
 {
     SchemaObjectInfo schemaObjectInfo;
     if (schemaInfo.TryGetValue(typeName, out schemaObjectInfo))
     {
         return schemaObjectInfo.type;
     }
     return null;
 }
コード例 #4
0
ファイル: SchemaHelper.cs プロジェクト: dotnet/corefx
 internal static XmlSchema GetSchemaWithType(SchemaObjectDictionary schemaInfo, XmlSchemaSet schemas, XmlQualifiedName typeName)
 {
     SchemaObjectInfo schemaObjectInfo;
     if (schemaInfo.TryGetValue(typeName, out schemaObjectInfo))
     {
         if (schemaObjectInfo.schema != null)
             return schemaObjectInfo.schema;
     }
     ICollection currentSchemas = schemas.Schemas();
     string ns = typeName.Namespace;
     foreach (XmlSchema schema in currentSchemas)
     {
         if (NamespacesEqual(ns, schema.TargetNamespace))
         {
             return schema;
         }
     }
     return null;
 }
コード例 #5
0
        internal static XmlSchema GetSchemaWithType(SchemaObjectDictionary schemaInfo, XmlSchemaSet schemas, XmlQualifiedName typeName)
        {
            if (schemaInfo.TryGetValue(typeName, out SchemaObjectInfo schemaObjectInfo))
            {
                if (schemaObjectInfo.schema != null)
                {
                    return(schemaObjectInfo.schema);
                }
            }
            ICollection currentSchemas = schemas.Schemas();
            string      ns             = typeName.Namespace;

            foreach (XmlSchema schema in currentSchemas)
            {
                if (NamespacesEqual(ns, schema.TargetNamespace))
                {
                    return(schema);
                }
            }
            return(null);
        }
コード例 #6
0
ファイル: SchemaHelper.cs プロジェクト: dotnet/corefx
 internal static XmlSchemaElement GetSchemaElement(SchemaObjectDictionary schemaInfo, XmlQualifiedName elementName)
 {
     SchemaObjectInfo schemaObjectInfo;
     if (schemaInfo.TryGetValue(elementName, out schemaObjectInfo))
     {
         return schemaObjectInfo.element;
     }
     return null;
 }