System.Xml.Schema.XmlSchemaImport Class

Assembly: System.Xml.dll
Namespace: System.Xml.Schema
Summary
The class to import schema components from any schema. Represents the World Wide Web Consortium (W3C) import element.
C# Syntax:
public class XmlSchemaImport : XmlSchemaExternal
Remarks
XmlSchemaImport allows references to schema components from other schemas with different target namespaces.
Example
See XmlSchemaInclude for an example using this class.
See also:
System.Xml.Schema Namespace

System.Xml.Schema.XmlSchemaImport Member List:

Public Constructors
ctor #1 Default constructor. This constructor is called by derived class constructors to initialize state in this type.
Public Properties
Annotation Read-write

Gets or sets the annotation property.
Id
(inherited from System.Xml.Schema.XmlSchemaExternal)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaExternal.Id


Gets or sets the string id.
LineNumber
(inherited from System.Xml.Schema.XmlSchemaObject)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaObject.LineNumber


Gets or sets the line number in the file to which the schema element refers.
LinePosition
(inherited from System.Xml.Schema.XmlSchemaObject)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaObject.LinePosition


Gets or sets the line position in the file to which the schema element refers.
Namespace Read-write

Gets or sets the target namespace for the imported schema as a URI reference.
Namespaces
(inherited from System.Xml.Schema.XmlSchemaObject)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaObject.Namespaces


Schema
(inherited from System.Xml.Schema.XmlSchemaExternal)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaExternal.Schema


Gets or sets the XmlSchema for the referenced schema.
SchemaLocation
(inherited from System.Xml.Schema.XmlSchemaExternal)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaExternal.SchemaLocation


Gets or sets the URI location for the schema, which tells the schema processor where the schema physically resides.
SourceUri
(inherited from System.Xml.Schema.XmlSchemaObject)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaObject.SourceUri


Gets or sets the source location for the file that loaded the schema.
UnhandledAttributes
(inherited from System.Xml.Schema.XmlSchemaExternal)
Read-write

See base class member description: System.Xml.Schema.XmlSchemaExternal.UnhandledAttributes


Gets and sets the qualified attributes which do not belong to the schema target namespace.
Public Methods
Equals
(inherited from System.Object)
See base class member description: System.Object.Equals

Derived from System.Object, the primary base class for all objects.
GetHashCode
(inherited from System.Object)
See base class member description: System.Object.GetHashCode

Derived from System.Object, the primary base class for all objects.
GetType
(inherited from System.Object)
See base class member description: System.Object.GetType

Derived from System.Object, the primary base class for all objects.
ToString
(inherited from System.Object)
See base class member description: System.Object.ToString

Derived from System.Object, the primary base class for all objects.
Protected Methods
Finalize
(inherited from System.Object)
See base class member description: System.Object.Finalize

Derived from System.Object, the primary base class for all objects.
MemberwiseClone
(inherited from System.Object)
See base class member description: System.Object.MemberwiseClone

Derived from System.Object, the primary base class for all objects.

Hierarchy:


System.Xml.Schema.XmlSchemaImport Member Details

ctor #1
Summary:
Default constructor. This constructor is called by derived class constructors to initialize state in this type.
C# Syntax:
public XmlSchemaImport();

Return to top


Property: Annotation (read-write)
Summary
Gets or sets the annotation property.
C# Syntax:
public XmlSchemaAnnotation Annotation {get; set;}

Return to top


Property: Id (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaExternal.Id

Summary
Gets or sets the string id.
C# Syntax:
public string Id {get; set;}

Return to top


Property: LineNumber (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaObject.LineNumber

Summary
Gets or sets the line number in the file to which the schema element refers.
C# Syntax:
public int LineNumber {get; set;}
Remarks
LineNumber is used to store the line number when a schema is read from a file. This is reported through XmlSchemaException for error handling.

Return to top


Property: LinePosition (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaObject.LinePosition

Summary
Gets or sets the line position in the file to which the schema element refers.
C# Syntax:
public int LinePosition {get; set;}
Remarks
This is used to store the line position when a schema is read from a file. This is reported through XmlSchemaException for error handling.

Return to top


Property: Namespace (read-write)
Summary
Gets or sets the target namespace for the imported schema as a URI reference.
C# Syntax:
public string Namespace {get; set;}
Remarks
The namespace attribute indicates that the containing schema document may contain qualified references to schema components in that namespace through one or more prefixes that are declared with xmlns attributes. If this attribute is absent, the containing schema can contain unqualified references to components in the imported namespace.

Return to top


Property: Namespaces (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaObject.Namespaces

C# Syntax:
public XmlSerializerNamespaces Namespaces {get; set;}

Return to top


Property: Schema (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaExternal.Schema

Summary
Gets or sets the XmlSchema for the referenced schema.
C# Syntax:
public XmlSchema Schema {get; set;}

Return to top


Property: SchemaLocation (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaExternal.SchemaLocation

Summary
Gets or sets the URI location for the schema, which tells the schema processor where the schema physically resides.
C# Syntax:
public string SchemaLocation {get; set;}
Remarks
Imported schemas that do not have this attribute allow the imported schema's namespace to be determined by the XML document that is an instance of the containing schema or the application that is processing the schema.

Included schemas use this attribute as the URI reference to the location of a schema document that should be included in the target namespace of the containing schema.

Return to top


Property: SourceUri (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaObject.SourceUri

Summary
Gets or sets the source location for the file that loaded the schema.
C# Syntax:
public string SourceUri {get; set;}
Remarks
Provides information for exception handling.

Return to top


Property: UnhandledAttributes (read-write)
Inherited
See base class member description: System.Xml.Schema.XmlSchemaExternal.UnhandledAttributes

Summary
Gets and sets the qualified attributes which do not belong to the schema target namespace.
C# Syntax:
public XmlAttribute[] UnhandledAttributes {get; set;}

Return to top


Method: Equals(
   object obj
)
Inherited
See base class member description: System.Object.Equals
C# Syntax:
public virtual bool Equals(
   object obj
);

For more information on members inherited from System.Object click on the link above.

Return to top


Method: Finalize()
Inherited
See base class member description: System.Object.Finalize
C# Syntax:
~XmlSchemaImport();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: GetHashCode()
Inherited
See base class member description: System.Object.GetHashCode
C# Syntax:
public virtual int GetHashCode();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: GetType()
Inherited
See base class member description: System.Object.GetType
C# Syntax:
public Type GetType();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: MemberwiseClone()
Inherited
See base class member description: System.Object.MemberwiseClone
C# Syntax:
protected object MemberwiseClone();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: ToString()
Inherited
See base class member description: System.Object.ToString
C# Syntax:
public virtual string ToString();

For more information on members inherited from System.Object click on the link above.

Return to top


Top of page

Copyright (c) 2002 Microsoft Corporation. All rights reserved.