C# 클래스 MS.Internal.Xml.Cache.XPathDocumentNavigator

This is the default XPath/XQuery data model cache implementation. It will be used whenever the user does not supply his own XPathNavigator implementation.
상속: System.Xml.XPath.XPathNavigator, IXmlLineInfo
파일 보기 프로젝트 열기: gbarnett/shared-source-cli-2.0 1 사용 예제들

Private Properties

프로퍼티 타입 설명
GetFollowingEnd int
GetPrimaryLocation int
GetSecondaryLocation int

공개 메소드들

메소드 설명
Clone ( ) : XPathNavigator

Create a copy of this navigator, positioned to the same node in the tree.

ComparePosition ( XPathNavigator other ) : XmlNodeOrder

Returns: XmlNodeOrder.Unknown -- This navigator and the "other" navigator are not of the same type, or the navigator's are not positioned on nodes in the same document. XmlNodeOrder.Before -- This navigator's current node is before the "other" navigator's current node in document order. XmlNodeOrder.After -- This navigator's current node is after the "other" navigator's current node in document order. XmlNodeOrder.Same -- This navigator is positioned on the same node as the "other" navigator.

GetPositionHashCode ( ) : int

Get hashcode based on current position of the navigator.

HasLineInfo ( ) : bool

Return true if line number information is recorded in the cache.

IsContentKindMatch ( XPathNodeType typ ) : bool

Return true if navigator is positioned to a content node of the specified kind. Whitespace/SignficantWhitespace/Text are all treated the same (i.e. they all match each other).

IsDescendant ( XPathNavigator other ) : bool

Return true if the "other" navigator's current node is a descendant of this navigator's current node.

IsElementMatch ( string localName, string namespaceURI ) : bool

Return true if navigator is positioned to an element having the specified name.

IsKindMatch ( XPathNodeType typ ) : bool

Return true if navigator is positioned to a node of the specified kind. Whitespace/SignficantWhitespace/Text are all treated the same (i.e. they all match each other).

IsSamePosition ( XPathNavigator other ) : bool

Returns true if this navigator is positioned to the same node as the "other" navigator. Returns false if not, or if the "other" navigator is not the same type as this navigator.

MoveTo ( XPathNavigator other ) : bool

Position this navigator to the same position as the "other" navigator. If the "other" navigator is not of the same type as this navigator, then return false.

MoveToAttribute ( string localName, string namespaceURI ) : bool

Position the navigator on the attribute with the specified name and return true. If no matching attribute can be found, return false. Don't assume the name parts are atomized with respect to this document.

MoveToChild ( XPathNodeType type ) : bool

Move to the first content child of the current node with the specified type. Return false if the current node has no matching children.

MoveToChild ( string localName, string namespaceURI ) : bool

Move to the first element child of the current node with the specified name. Return false if the current node has no matching element children.

MoveToFirstAttribute ( ) : bool

Position the navigator on the first attribute of the current node and return true. If no attributes can be found, return false.

MoveToFirstChild ( ) : bool

Move to the first content-typed child of the current node. Return false if the current node has no content children.

MoveToFirstNamespace ( XPathNamespaceScope namespaceScope ) : bool

Position the navigator on the namespace within the specified scope. If no matching namespace can be found, return false.

MoveToFollowing ( XPathNodeType type, XPathNavigator end ) : bool

Move to the next node that: 1. Follows the current node in document order (includes descendants, unlike XPath following axis) 2. Precedes "end" in document order (if end is null, then all following nodes in the document are considered) 3. Has the specified XPathNodeType Return false if the current node has no matching following nodes.

MoveToFollowing ( string localName, string namespaceURI, XPathNavigator end ) : bool

Move to the next element that: 1. Follows the current node in document order (includes descendants, unlike XPath following axis) 2. Precedes "end" in document order (if end is null, then all following nodes in the document are considered) 3. Has the specified QName Return false if the current node has no matching following elements.

MoveToId ( string id ) : bool

Position to the navigator to the element whose id is equal to the specified "id" string.

MoveToNext ( ) : bool

If the current node is an attribute or namespace (not content), return false. Otherwise, move to the next content node. Return false if there are no more content nodes.

MoveToNext ( XPathNodeType type ) : bool

Move to the first content sibling of the current node with the specified type. Return false if the current node has no matching siblings.

MoveToNext ( string localName, string namespaceURI ) : bool

Move to the first element sibling of the current node with the specified name. Return false if the current node has no matching element siblings.

MoveToNextAttribute ( ) : bool

If positioned on an attribute, move to its next sibling attribute. If no attributes can be found, return false.

MoveToNextNamespace ( XPathNamespaceScope scope ) : bool

Position the navigator on the next namespace within the specified scope. If no matching namespace can be found, return false.

MoveToParent ( ) : bool

Position the navigator on the parent of the current node. If the current node has no parent, return false.

MoveToPrevious ( ) : bool

If the current node is an attribute or namespace (not content), return false. Otherwise, move to the previous (sibling) content node. Return false if there are no previous content nodes.

MoveToRoot ( ) : void

Position the navigator on the root node of the current document.

SelectChildren ( XPathNodeType type ) : XPathNodeIterator

Return an iterator that ranges over all children of the current node that match the specified XPathNodeType.

SelectChildren ( string name, string namespaceURI ) : XPathNodeIterator

Return an iterator that ranges over all children of the current node that match the specified QName.

SelectDescendants ( XPathNodeType type, bool matchSelf ) : XPathNodeIterator

Return an iterator that ranges over all descendants of the current node that match the specified XPathNodeType. If matchSelf is true, then also perform the match on the current node.

SelectDescendants ( string name, string namespaceURI, bool matchSelf ) : XPathNodeIterator

Return an iterator that ranges over all descendants of the current node that match the specified QName. If matchSelf is true, then also perform the match on the current node.

XPathDocumentNavigator ( XPathDocumentNavigator nav ) : System

Copy constructor.

XPathDocumentNavigator ( XPathNode pageCurrent, int idxCurrent, XPathNode pageParent, int idxParent ) : System

Create a new navigator positioned on the specified current node. If the current node is a namespace or a collapsed text node, then the parent is a virtualized parent (may be different than .Parent on the current node).

비공개 메소드들

메소드 설명
GetFollowingEnd ( XPathDocumentNavigator end, bool useParentOfVirtual, XPathNode &pageEnd ) : int

"end" is positioned on a node which terminates a following scan. Return the page and index of "end" if it is positioned to a non-virtual node. If "end" is positioned to a virtual node: 1. If useParentOfVirtual is true, then return the page and index of the virtual node's parent 2. If useParentOfVirtual is false, then return the page and index of the virtual node's parent + 1.

GetPrimaryLocation ( ) : int

Construct a primary location for this navigator. The location is an integer that can be easily compared with other locations in the same document in order to determine the relative document order of two nodes. If two locations compare equal, then secondary locations should be compared.

GetSecondaryLocation ( ) : int

Construct a secondary location for this navigator. This location should only be used if primary locations previously compared equal.

메소드 상세

Clone() 공개 메소드

Create a copy of this navigator, positioned to the same node in the tree.
public Clone ( ) : XPathNavigator
리턴 System.Xml.XPath.XPathNavigator

ComparePosition() 공개 메소드

Returns: XmlNodeOrder.Unknown -- This navigator and the "other" navigator are not of the same type, or the navigator's are not positioned on nodes in the same document. XmlNodeOrder.Before -- This navigator's current node is before the "other" navigator's current node in document order. XmlNodeOrder.After -- This navigator's current node is after the "other" navigator's current node in document order. XmlNodeOrder.Same -- This navigator is positioned on the same node as the "other" navigator.
public ComparePosition ( XPathNavigator other ) : XmlNodeOrder
other System.Xml.XPath.XPathNavigator
리턴 XmlNodeOrder

GetPositionHashCode() 공개 메소드

Get hashcode based on current position of the navigator.
public GetPositionHashCode ( ) : int
리턴 int

HasLineInfo() 공개 메소드

Return true if line number information is recorded in the cache.
public HasLineInfo ( ) : bool
리턴 bool

IsContentKindMatch() 공개 메소드

Return true if navigator is positioned to a content node of the specified kind. Whitespace/SignficantWhitespace/Text are all treated the same (i.e. they all match each other).
public IsContentKindMatch ( XPathNodeType typ ) : bool
typ XPathNodeType
리턴 bool

IsDescendant() 공개 메소드

Return true if the "other" navigator's current node is a descendant of this navigator's current node.
public IsDescendant ( XPathNavigator other ) : bool
other System.Xml.XPath.XPathNavigator
리턴 bool

IsElementMatch() 공개 메소드

Return true if navigator is positioned to an element having the specified name.
public IsElementMatch ( string localName, string namespaceURI ) : bool
localName string
namespaceURI string
리턴 bool

IsKindMatch() 공개 메소드

Return true if navigator is positioned to a node of the specified kind. Whitespace/SignficantWhitespace/Text are all treated the same (i.e. they all match each other).
public IsKindMatch ( XPathNodeType typ ) : bool
typ XPathNodeType
리턴 bool

IsSamePosition() 공개 메소드

Returns true if this navigator is positioned to the same node as the "other" navigator. Returns false if not, or if the "other" navigator is not the same type as this navigator.
public IsSamePosition ( XPathNavigator other ) : bool
other System.Xml.XPath.XPathNavigator
리턴 bool

MoveTo() 공개 메소드

Position this navigator to the same position as the "other" navigator. If the "other" navigator is not of the same type as this navigator, then return false.
public MoveTo ( XPathNavigator other ) : bool
other System.Xml.XPath.XPathNavigator
리턴 bool

MoveToAttribute() 공개 메소드

Position the navigator on the attribute with the specified name and return true. If no matching attribute can be found, return false. Don't assume the name parts are atomized with respect to this document.
public MoveToAttribute ( string localName, string namespaceURI ) : bool
localName string
namespaceURI string
리턴 bool

MoveToChild() 공개 메소드

Move to the first content child of the current node with the specified type. Return false if the current node has no matching children.
public MoveToChild ( XPathNodeType type ) : bool
type XPathNodeType
리턴 bool

MoveToChild() 공개 메소드

Move to the first element child of the current node with the specified name. Return false if the current node has no matching element children.
public MoveToChild ( string localName, string namespaceURI ) : bool
localName string
namespaceURI string
리턴 bool

MoveToFirstAttribute() 공개 메소드

Position the navigator on the first attribute of the current node and return true. If no attributes can be found, return false.
public MoveToFirstAttribute ( ) : bool
리턴 bool

MoveToFirstChild() 공개 메소드

Move to the first content-typed child of the current node. Return false if the current node has no content children.
public MoveToFirstChild ( ) : bool
리턴 bool

MoveToFirstNamespace() 공개 메소드

Position the navigator on the namespace within the specified scope. If no matching namespace can be found, return false.
public MoveToFirstNamespace ( XPathNamespaceScope namespaceScope ) : bool
namespaceScope XPathNamespaceScope
리턴 bool

MoveToFollowing() 공개 메소드

Move to the next node that: 1. Follows the current node in document order (includes descendants, unlike XPath following axis) 2. Precedes "end" in document order (if end is null, then all following nodes in the document are considered) 3. Has the specified XPathNodeType Return false if the current node has no matching following nodes.
public MoveToFollowing ( XPathNodeType type, XPathNavigator end ) : bool
type XPathNodeType
end System.Xml.XPath.XPathNavigator
리턴 bool

MoveToFollowing() 공개 메소드

Move to the next element that: 1. Follows the current node in document order (includes descendants, unlike XPath following axis) 2. Precedes "end" in document order (if end is null, then all following nodes in the document are considered) 3. Has the specified QName Return false if the current node has no matching following elements.
public MoveToFollowing ( string localName, string namespaceURI, XPathNavigator end ) : bool
localName string
namespaceURI string
end System.Xml.XPath.XPathNavigator
리턴 bool

MoveToId() 공개 메소드

Position to the navigator to the element whose id is equal to the specified "id" string.
public MoveToId ( string id ) : bool
id string
리턴 bool

MoveToNext() 공개 메소드

If the current node is an attribute or namespace (not content), return false. Otherwise, move to the next content node. Return false if there are no more content nodes.
public MoveToNext ( ) : bool
리턴 bool

MoveToNext() 공개 메소드

Move to the first content sibling of the current node with the specified type. Return false if the current node has no matching siblings.
public MoveToNext ( XPathNodeType type ) : bool
type XPathNodeType
리턴 bool

MoveToNext() 공개 메소드

Move to the first element sibling of the current node with the specified name. Return false if the current node has no matching element siblings.
public MoveToNext ( string localName, string namespaceURI ) : bool
localName string
namespaceURI string
리턴 bool

MoveToNextAttribute() 공개 메소드

If positioned on an attribute, move to its next sibling attribute. If no attributes can be found, return false.
public MoveToNextAttribute ( ) : bool
리턴 bool

MoveToNextNamespace() 공개 메소드

Position the navigator on the next namespace within the specified scope. If no matching namespace can be found, return false.
public MoveToNextNamespace ( XPathNamespaceScope scope ) : bool
scope XPathNamespaceScope
리턴 bool

MoveToParent() 공개 메소드

Position the navigator on the parent of the current node. If the current node has no parent, return false.
public MoveToParent ( ) : bool
리턴 bool

MoveToPrevious() 공개 메소드

If the current node is an attribute or namespace (not content), return false. Otherwise, move to the previous (sibling) content node. Return false if there are no previous content nodes.
public MoveToPrevious ( ) : bool
리턴 bool

MoveToRoot() 공개 메소드

Position the navigator on the root node of the current document.
public MoveToRoot ( ) : void
리턴 void

SelectChildren() 공개 메소드

Return an iterator that ranges over all children of the current node that match the specified XPathNodeType.
public SelectChildren ( XPathNodeType type ) : XPathNodeIterator
type XPathNodeType
리턴 System.Xml.XPath.XPathNodeIterator

SelectChildren() 공개 메소드

Return an iterator that ranges over all children of the current node that match the specified QName.
public SelectChildren ( string name, string namespaceURI ) : XPathNodeIterator
name string
namespaceURI string
리턴 System.Xml.XPath.XPathNodeIterator

SelectDescendants() 공개 메소드

Return an iterator that ranges over all descendants of the current node that match the specified XPathNodeType. If matchSelf is true, then also perform the match on the current node.
public SelectDescendants ( XPathNodeType type, bool matchSelf ) : XPathNodeIterator
type XPathNodeType
matchSelf bool
리턴 System.Xml.XPath.XPathNodeIterator

SelectDescendants() 공개 메소드

Return an iterator that ranges over all descendants of the current node that match the specified QName. If matchSelf is true, then also perform the match on the current node.
public SelectDescendants ( string name, string namespaceURI, bool matchSelf ) : XPathNodeIterator
name string
namespaceURI string
matchSelf bool
리턴 System.Xml.XPath.XPathNodeIterator

XPathDocumentNavigator() 공개 메소드

Copy constructor.
public XPathDocumentNavigator ( XPathDocumentNavigator nav ) : System
nav XPathDocumentNavigator
리턴 System

XPathDocumentNavigator() 공개 메소드

Create a new navigator positioned on the specified current node. If the current node is a namespace or a collapsed text node, then the parent is a virtualized parent (may be different than .Parent on the current node).
public XPathDocumentNavigator ( XPathNode pageCurrent, int idxCurrent, XPathNode pageParent, int idxParent ) : System
pageCurrent XPathNode
idxCurrent int
pageParent XPathNode
idxParent int
리턴 System