XmlQueryRuntime.MatchesXmlType 方法

定义

如果指定项的类型与指定的 XML 类型匹配,则返回 trueReturns true if the type of the specified item matches the specified XML type.

重载

MatchesXmlType(IList<XPathItem>, Int32)

如果指定序列中每个项的类型与指定索引所标识的 XML 类型匹配,则返回 trueReturns true if the type of every item in the specified sequence matches the XML type that the specified index identifies.

MatchesXmlType(IList<XPathItem>, XmlTypeCode)

确定指定序列的类型是否为指定的单一实例类型的子类型。Determines whether the type of the specified sequence is a subtype of the specified singleton type.

MatchesXmlType(XPathItem, Int32)

如果指定的 XPathItem 对象的类型与指定的 XML 类型匹配,则返回 trueReturns true if the type of the specified XPathItem object matches the specified XML type.

MatchesXmlType(XPathItem, XmlTypeCode)

如果 XPathItem 对象的类型是由指定的 XmlTypeCode 标识的类型的子类型,则返回 trueReturns true if the type of the XPathItem object is a subtype of a type identified by the specified XmlTypeCode.

MatchesXmlType(IList<XPathItem>, Int32)

如果指定序列中每个项的类型与指定索引所标识的 XML 类型匹配,则返回 trueReturns true if the type of every item in the specified sequence matches the XML type that the specified index identifies.

public:
 bool MatchesXmlType(System::Collections::Generic::IList<System::Xml::XPath::XPathItem ^> ^ seq, int indexType);
public bool MatchesXmlType (System.Collections.Generic.IList<System.Xml.XPath.XPathItem> seq, int indexType);
member this.MatchesXmlType : System.Collections.Generic.IList<System.Xml.XPath.XPathItem> * int -> bool
Public Function MatchesXmlType (seq As IList(Of XPathItem), indexType As Integer) As Boolean

参数

seq
IList<XPathItem>

IList<T> 对象的 XPathItemAn IList<T> of XPathItem objects.

indexType
Int32

索引。The index.

返回

Boolean

如果 seq 的类型是 indexType 的子类型,则为 true;否则为 falsetrue if the type of seq is a subtype of the indexType; otherwise, false.

适用于

MatchesXmlType(IList<XPathItem>, XmlTypeCode)

确定指定序列的类型是否为指定的单一实例类型的子类型。Determines whether the type of the specified sequence is a subtype of the specified singleton type.

public:
 bool MatchesXmlType(System::Collections::Generic::IList<System::Xml::XPath::XPathItem ^> ^ seq, System::Xml::Schema::XmlTypeCode code);
public bool MatchesXmlType (System.Collections.Generic.IList<System.Xml.XPath.XPathItem> seq, System.Xml.Schema.XmlTypeCode code);
member this.MatchesXmlType : System.Collections.Generic.IList<System.Xml.XPath.XPathItem> * System.Xml.Schema.XmlTypeCode -> bool
Public Function MatchesXmlType (seq As IList(Of XPathItem), code As XmlTypeCode) As Boolean

参数

seq
IList<XPathItem>

一个 XPathItem 实例的序列。A sequence of XPathItem instances.

code
XmlTypeCode

单一实例类型。A singleton type.

返回

Boolean

如果 seq 的类型是 code 所指定类型的子类型,则为 true;否则为 falsetrue if the type of seq is a subtype the type specified by code; otherwise, false.

适用于

MatchesXmlType(XPathItem, Int32)

如果指定的 XPathItem 对象的类型与指定的 XML 类型匹配,则返回 trueReturns true if the type of the specified XPathItem object matches the specified XML type.

public:
 bool MatchesXmlType(System::Xml::XPath::XPathItem ^ item, int indexType);
public bool MatchesXmlType (System.Xml.XPath.XPathItem item, int indexType);
member this.MatchesXmlType : System.Xml.XPath.XPathItem * int -> bool
Public Function MatchesXmlType (item As XPathItem, indexType As Integer) As Boolean

参数

item
XPathItem

XPathItem 类的实例。An instance of the XPathItem class.

indexType
Int32

XML 类型的数组中的索引。The index in the array of XML types.

返回

Boolean

如果指定的 XPathItem 的类型与指定的 XML 类型匹配,则返回 true;否则返回 falsetrue if the type of the specified XPathItem matches the specified XML type; otherwise, false.

适用于

MatchesXmlType(XPathItem, XmlTypeCode)

如果 XPathItem 对象的类型是由指定的 XmlTypeCode 标识的类型的子类型,则返回 trueReturns true if the type of the XPathItem object is a subtype of a type identified by the specified XmlTypeCode.

public:
 bool MatchesXmlType(System::Xml::XPath::XPathItem ^ item, System::Xml::Schema::XmlTypeCode code);
public bool MatchesXmlType (System.Xml.XPath.XPathItem item, System.Xml.Schema.XmlTypeCode code);
member this.MatchesXmlType : System.Xml.XPath.XPathItem * System.Xml.Schema.XmlTypeCode -> bool
Public Function MatchesXmlType (item As XPathItem, code As XmlTypeCode) As Boolean

参数

item
XPathItem

XPathItem 类的实例。An instance of the XPathItem class.

code
XmlTypeCode

XmlTypeCode 类的实例。An instance of the XmlTypeCode class.

返回

Boolean

如果 XPathItem 对象的类型是由指定的 XmlTypeCode 标识的类型的子类型,则为 true;否则为 falsetrue if the type of the XPathItem object is a subtype of a type identified by the specified XmlTypeCode; otherwise, false.

适用于