java.lang.Object
javax.xml.crypto.dsig.spec.XPathType
XML Schema Definition of the
XPath
element as defined in the W3C Recommendation for XML-Signature XPath Filter 2.0:
<schema xmlns="http://www.w3.org/2001/XMLSchema"
xmlns:xf="http://www.w3.org/2002/06/xmldsig-filter2"
targetNamespace="http://www.w3.org/2002/06/xmldsig-filter2"
version="0.1" elementFormDefault="qualified">
<element name="XPath"
type="xf:XPathType"/>
<complexType name="XPathType">
<simpleContent>
<extension base="string">
<attribute name="Filter">
<simpleType>
<restriction base="string">
<enumeration value="intersect"/>
<enumeration value="subtract"/>
<enumeration value="union"/>
</restriction>
</simpleType>
</attribute>
</extension>
</simpleContent>
</complexType>
- 自版本:
- 1.6
- 参见:
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionXPathType
(String expression, XPathType.Filter filter) 使用指定的XPath表达式和过滤器创建一个XPathType
实例。使用指定的XPath表达式、过滤器和命名空间映射创建一个XPathType
实例。 -
Method Summary
Modifier and TypeMethodDescription返回要评估的XPath表达式。返回过滤操作。返回命名空间前缀的映射。
-
Constructor Details
-
XPathType
使用指定的XPath表达式和过滤器创建一个XPathType
实例。- 参数:
-
expression
- 要评估的XPath表达式 -
filter
- 过滤操作(XPathType.Filter.INTERSECT
、XPathType.Filter.SUBTRACT
或XPathType.Filter.UNION
) - 抛出:
-
NullPointerException
- 如果expression
或filter
为null
-
XPathType
使用指定的XPath表达式、过滤器和命名空间映射创建一个XPathType
实例。为防止后续修改,将映射复制。- 参数:
-
expression
- 要评估的XPath表达式 -
filter
- 过滤操作(XPathType.Filter.INTERSECT
、XPathType.Filter.SUBTRACT
或XPathType.Filter.UNION
) -
namespaceMap
- 命名空间前缀的映射。每个键是一个命名空间前缀String
,映射到相应的命名空间URIString
。 - 抛出:
-
NullPointerException
- 如果expression
、filter
或namespaceMap
为null
-
ClassCastException
- 如果映射的任何键或条目不是String
类型
-
-
Method Details
-
getExpression
返回要评估的XPath表达式。- 返回:
- 要评估的XPath表达式
-
getFilter
返回过滤操作。- 返回:
- 过滤操作
-
getNamespaceMap
- 返回:
-
一个命名空间前缀到命名空间URI的
Map
(可能为空,但不会为null
)
-