play.libs.XPath.selectNodes()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(2.9k)|赞(0)|评价(0)|浏览(129)

本文整理了Java中play.libs.XPath.selectNodes()方法的一些代码示例,展示了XPath.selectNodes()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XPath.selectNodes()方法的具体详情如下:
包路径:play.libs.XPath
类名称:XPath
方法名:selectNodes

XPath.selectNodes介绍

[英]Select all nodes that are selected by this XPath expression. If multiple nodes match, multiple nodes will be returned. Nodes will be returned in document-order,
[中]选择此XPath表达式选择的所有节点。如果多个节点匹配,将返回多个节点。节点将按文档顺序返回,

代码示例

代码示例来源:origin: com.typesafe.play/play-java_2.11

/**
 * Select all nodes that are selected by this XPath expression. If multiple nodes match,
 * multiple nodes will be returned. Nodes will be returned in document-order,
 * @param path the xpath expression
 * @param node the starting node
 * @return result of evaluating the xpath expression against node
 */
public static NodeList selectNodes(String path, Object node) {
  return selectNodes(path, node, null);
}

代码示例来源:origin: com.typesafe.play/play-java_2.12

/**
 * Select all nodes that are selected by this XPath expression. If multiple nodes match,
 * multiple nodes will be returned. Nodes will be returned in document-order,
 * @param path the xpath expression
 * @param node the starting node
 * @return result of evaluating the xpath expression against node
 */
public static NodeList selectNodes(String path, Object node) {
  return selectNodes(path, node, null);
}

代码示例来源:origin: com.typesafe.play/play-java_2.10

/**
 * Select all nodes that are selected by this XPath expression. If multiple nodes match,
 * multiple nodes will be returned. Nodes will be returned in document-order,
 * @param path
 * @param node
 * @return
 */
public static NodeList selectNodes(String path, Object node) {
  return selectNodes(path, node, null);
}

代码示例来源:origin: com.typesafe.play/play-java

/**
 * Select all nodes that are selected by this XPath expression. If multiple nodes match,
 * multiple nodes will be returned. Nodes will be returned in document-order,
 * @param path the xpath expression
 * @param node the starting node
 * @return result of evaluating the xpath expression against node
 */
public static NodeList selectNodes(String path, Object node) {
  return selectNodes(path, node, null);
}

代码示例来源:origin: play/play-java

/**
 * Select all nodes that are selected by this XPath expression. If multiple nodes match,
 * multiple nodes will be returned. Nodes will be returned in document-order,
 * @param path
 * @param node
 * @return
 */
public static NodeList selectNodes(String path, Object node) {
  return selectNodes(path, node, null);
}

代码示例来源:origin: com.google.code.maven-play-plugin.org.playframework/play

/**
 * Select all nodes that are selected by this XPath expression. If multiple nodes match, multiple nodes will be
 * returned. Nodes will be returned in document-order,
 * 
 * @param path
 *            Path expression
 * @param node
 *            The node object
 * @return Nodes in document-order
 */
public static List<Node> selectNodes(String path, Object node) {
  return selectNodes(path, node, null);
}

代码示例来源:origin: com.google.code.maven-play-plugin.org.playframework/play

public static Node selectNode(String path, Object node, Map<String, String> namespaces) {
  try {
    List<Node> nodes = selectNodes(path, node, namespaces);
    if (nodes.size() == 0) {
      return null;
    }
    return nodes.get(0);
  } catch (Exception e) {
    throw new RuntimeException(e);
  }
}

相关文章