public class XPath extends Object
| Constructor and Description |
|---|
XPath() |
| Modifier and Type | Method and Description |
|---|---|
static Node |
selectNode(String path,
Object node) |
static Node |
selectNode(String path,
Object node,
Map<String,String> namespaces) |
static List<Node> |
selectNodes(String path,
Object node)
Select all nodes that are selected by this XPath expression.
|
static List<Node> |
selectNodes(String path,
Object node,
Map<String,String> namespaces)
Select all nodes that are selected by this XPath expression.
|
static String |
selectText(String path,
Object node)
Return the text of a node, or the value of an attribute
|
static String |
selectText(String path,
Object node,
Map<String,String> namespaces)
Return the text of a node, or the value of an attribute
|
public static List<Node> selectNodes(String path, Object node, Map<String,String> namespaces)
path - node - namespaces - Namespaces that need to be available in the xpath, where the key is the
prefix and the value the namespace URIpublic static List<Node> selectNodes(String path, Object node)
path - node - public static String selectText(String path, Object node, Map<String,String> namespaces)
path - the XPath to executenode - the node, node-set or Context object for evaluation. This value can be null.Guillaume Bort & zenexity - Distributed under Apache 2 licence, without any warrantly