C# Class Mvp.Xml.XInclude.XIncludingReader

XIncludingReader class implements streamable subset of the XInclude 1.0 in a fast, non-caching, forward-only fashion. To put it another way XIncludingReader is XML Base and XInclude 1.0 aware XmlReader.

See XInclude.NET homepage for more info.

Author: Oleg Tkachenko, http://www.xmllab.net.

Inheritance: XmlReader, IXmlLineInfo
Afficher le fichier Open project: Monobjc/monobjc-tools Class Usage Examples

Méthodes publiques

Méthode Description
Close ( ) : void

See XmlReader.Close

GetAttribute ( int i ) : string

See XmlReader.GetAttribute(int)

GetAttribute ( string name ) : string

See XmlReader.GetAttribute(string)

GetAttribute ( string name, string namespaceURI ) : string

See XmlReader.GetAttribute(string, string)

HasLineInfo ( ) : bool

Gets a value indicating whether the class can return line information. See IXmlLineInfo.HasLineInfo.

LookupNamespace ( String prefix ) : String

See XmlReader.LookupNamespace

MoveToAttribute ( string name ) : bool

See XmlReader.MoveToAttribute(string)

MoveToAttribute ( string name, string ns ) : bool

See XmlReader.MoveToAttribute(string, string)

MoveToAttribute ( int i ) : void

See XmlReader.MoveToAttribute(int)

MoveToElement ( ) : bool

See XmlReader.MoveToElement

MoveToFirstAttribute ( ) : bool

See XmlReader.MoveToFirstAttribute

MoveToNextAttribute ( ) : bool

See XmlReader.MoveToNextAttribute

Read ( ) : bool

See XmlReader.Read

ReadAttributeValue ( ) : bool

See XmlReader.ReadAttributeValue

ReadInnerXml ( ) : string

See XmlReader.ReadInnerXml

ReadOuterXml ( ) : string

See XmlReader.ReadOuterXml

ReadString ( ) : string

See XmlReader.ReadString

ResolveEntity ( ) : void

See XmlReader.ResolveEntity

XIncludingReader ( Stream input ) : System

Creates new instance of XIncludingReader class with specified Stream.

XIncludingReader ( Stream input, XmlNameTable nt ) : System

Creates new instance of XIncludingReader class with specified Stream and nametable.

XIncludingReader ( TextReader reader ) : System

Creates new instance of XIncludingReader class with specified TextReader reader.

XIncludingReader ( TextReader reader, XmlNameTable nt ) : System

Creates new instance of XIncludingReader class with specified TextReader reader and nametable.

XIncludingReader ( XmlReader reader ) : System

Creates new instance of XIncludingReader class with specified underlying XmlReader reader.

XIncludingReader ( string url ) : System

Creates new instance of XIncludingReader class with specified URL.

XIncludingReader ( string url, Stream input ) : System

Creates new instance of XIncludingReader class with specified URL and Stream.

XIncludingReader ( string url, Stream input, XmlNameTable nt ) : System

Creates new instance of XIncludingReader class with specified URL, Stream and nametable.

XIncludingReader ( string url, Stream input, XmlResolver resolver ) : System

Creates new instance of XIncludingReader class with specified URL, Stream and resolver.

XIncludingReader ( string url, TextReader reader ) : System

Creates new instance of XIncludingReader class with specified URL and TextReader reader.

XIncludingReader ( string url, TextReader reader, XmlNameTable nt ) : System

Creates new instance of XIncludingReader class with specified URL, TextReader reader and nametable.

XIncludingReader ( string url, XmlNameTable nt ) : System

Creates new instance of XIncludingReader class with specified URL and nametable.

XIncludingReader ( string url, XmlResolver resolver ) : System

Creates new instance of XIncludingReader class with specified URL and resolver.

this ( int i ) : String

See XmlReader.this[int]

this ( string name ) : string

See XmlReader.this[string]

this ( string name, string namespaceURI ) : string

See XmlReader.this[string, string]

Private Methods

Méthode Description
AreDifferentLangs ( string lang1, string lang2 ) : bool

Compares two languages as per IETF RFC 3066.

CheckAndSkipContent ( ) : void

Skips xi:include element's content, while checking XInclude syntax (no xi:include, no more than one xi:fallback).

CheckLoops ( Uri url, string xpointer ) : void

Checks for inclusion loops.

CreateAcquiredInfoset ( Uri includeLocation ) : string

Creates acquired infoset.

CreateAcquiredInfoset ( Uri includeLocation, TextReader reader ) : string

Creates acquired infoset.

CreateAcquiredInfoset ( XmlReader reader ) : string

Creates acquired infoset.

GetBaseUri ( ) : string
GetResource ( string includeLocation, string accept, string acceptLanguage, WebResponse &response ) : Stream

Fetches resource by URI.

IsFallbackElement ( XmlReader r ) : bool

/// Checks if given reader is positioned on a xi:fallback element.

IsIncludeElement ( XmlReader r ) : bool

Checks if given reader is positioned on a xi:include element.

ProcessFallback ( int depth, Exception e ) : bool

Fallback processing.

When inluding fails due to any resource error, xi:inlcude element content is processed as follows: each child xi:include - fatal error, more than one child xi:fallback - fatal error. No xi:fallback - the resource error results in a fatal error. Content of first xi:fallback element is included in a usual way.

ProcessIncludeElement ( ) : bool

Processes xi:include element.

ProcessInterDocTextInclusion ( string href ) : bool

Process inter-document inclusion as text.

ProcessInterDocXMLInclusion ( string href, string xpointer ) : bool

Processes inter-document inclusion (xml mode).

ResolveHref ( string href ) : Uri

Resolves include location.

SkipContent ( ) : void

Skips content of an element using directly current reader's methods.

ThrowCircularInclusionError ( XmlReader reader, Uri url ) : void

Throws CircularInclusionException.

ValidationCallback ( object sender, ValidationEventArgs args ) : void

Method Details

Close() public méthode

See XmlReader.Close
public Close ( ) : void
Résultat void

GetAttribute() public méthode

See XmlReader.GetAttribute(int)
public GetAttribute ( int i ) : string
i int
Résultat string

GetAttribute() public méthode

See XmlReader.GetAttribute(string)
public GetAttribute ( string name ) : string
name string
Résultat string

GetAttribute() public méthode

See XmlReader.GetAttribute(string, string)
public GetAttribute ( string name, string namespaceURI ) : string
name string
namespaceURI string
Résultat string

HasLineInfo() public méthode

Gets a value indicating whether the class can return line information. See IXmlLineInfo.HasLineInfo.
public HasLineInfo ( ) : bool
Résultat bool

LookupNamespace() public méthode

See XmlReader.LookupNamespace
public LookupNamespace ( String prefix ) : String
prefix String
Résultat String

MoveToAttribute() public méthode

See XmlReader.MoveToAttribute(string)
public MoveToAttribute ( string name ) : bool
name string
Résultat bool

MoveToAttribute() public méthode

See XmlReader.MoveToAttribute(string, string)
public MoveToAttribute ( string name, string ns ) : bool
name string
ns string
Résultat bool

MoveToAttribute() public méthode

See XmlReader.MoveToAttribute(int)
public MoveToAttribute ( int i ) : void
i int
Résultat void

MoveToElement() public méthode

See XmlReader.MoveToElement
public MoveToElement ( ) : bool
Résultat bool

MoveToFirstAttribute() public méthode

See XmlReader.MoveToFirstAttribute
public MoveToFirstAttribute ( ) : bool
Résultat bool

MoveToNextAttribute() public méthode

See XmlReader.MoveToNextAttribute
public MoveToNextAttribute ( ) : bool
Résultat bool

Read() public méthode

See XmlReader.Read
public Read ( ) : bool
Résultat bool

ReadAttributeValue() public méthode

See XmlReader.ReadAttributeValue
public ReadAttributeValue ( ) : bool
Résultat bool

ReadInnerXml() public méthode

See XmlReader.ReadInnerXml
public ReadInnerXml ( ) : string
Résultat string

ReadOuterXml() public méthode

See XmlReader.ReadOuterXml
public ReadOuterXml ( ) : string
Résultat string

ReadString() public méthode

See XmlReader.ReadString
public ReadString ( ) : string
Résultat string

ResolveEntity() public méthode

See XmlReader.ResolveEntity
public ResolveEntity ( ) : void
Résultat void

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified Stream.
public XIncludingReader ( Stream input ) : System
input Stream Stream.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified Stream and nametable.
public XIncludingReader ( Stream input, XmlNameTable nt ) : System
input Stream Stream.
nt System.Xml.XmlNameTable Nametable
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified TextReader reader.
public XIncludingReader ( TextReader reader ) : System
reader TextReader TextReader.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified TextReader reader and nametable.
public XIncludingReader ( TextReader reader, XmlNameTable nt ) : System
reader TextReader TextReader.
nt System.Xml.XmlNameTable Nametable.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified underlying XmlReader reader.
public XIncludingReader ( XmlReader reader ) : System
reader XmlReader Underlying reader to read from
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL.
public XIncludingReader ( string url ) : System
url string Document location.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL and Stream.
public XIncludingReader ( string url, Stream input ) : System
url string Source document's URL
input Stream Stream.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL, Stream and nametable.
public XIncludingReader ( string url, Stream input, XmlNameTable nt ) : System
url string Source document's URL
input Stream Stream.
nt System.Xml.XmlNameTable Nametable
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL, Stream and resolver.
public XIncludingReader ( string url, Stream input, XmlResolver resolver ) : System
url string Source document's URL
input Stream Stream.
resolver System.Xml.XmlResolver Resolver to acquire external resources.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL and TextReader reader.
public XIncludingReader ( string url, TextReader reader ) : System
url string Source document's URL
reader TextReader TextReader.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL, TextReader reader and nametable.
public XIncludingReader ( string url, TextReader reader, XmlNameTable nt ) : System
url string Source document's URI
reader TextReader TextReader.
nt System.Xml.XmlNameTable Nametable.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL and nametable.
public XIncludingReader ( string url, XmlNameTable nt ) : System
url string Document location.
nt System.Xml.XmlNameTable Name table.
Résultat System

XIncludingReader() public méthode

Creates new instance of XIncludingReader class with specified URL and resolver.
public XIncludingReader ( string url, XmlResolver resolver ) : System
url string Document location.
resolver System.Xml.XmlResolver Resolver to acquire external resources.
Résultat System

this() public méthode

See XmlReader.this[int]
public this ( int i ) : String
i int
Résultat String

this() public méthode

See XmlReader.this[string]
public this ( string name ) : string
name string
Résultat string

this() public méthode

See XmlReader.this[string, string]
public this ( string name, string namespaceURI ) : string
name string
namespaceURI string
Résultat string