gpt4 book ai didi

net.sf.saxon.sxpath.XPathStaticContext.getExecutable()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-26 23:31:05 27 4
gpt4 key购买 nike

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

XPathStaticContext.getExecutable介绍

[英]Get the executable associated with this static context. The Executable generally holds details of function libraries and collations. For freestanding XPath expressions, there will generally be a single executable corresponding one-to-one with the static context object, and which can be created as soon as the Configuration is known.
[中]获取与此静态上下文关联的可执行文件。可执行文件通常包含函数库和排序规则的详细信息。对于独立的XPath表达式,通常会有一个与静态上下文对象一一对应的可执行文件,只要知道配置,就可以创建它。

代码示例

代码示例来源:origin: net.sourceforge.saxon/saxon

/**
 * Get the executable
 * @return the executable. This holds details of function bindings and collations.
 */
public Executable getExecutable() {
  return staticContext.getExecutable();
}

代码示例来源:origin: org.opengis.cite.saxon/saxon9

/**
 * Get the executable
 * @return the executable. This holds details of function bindings and collations.
 */
public Executable getExecutable() {
  return staticContext.getExecutable();
}

代码示例来源:origin: net.sourceforge.saxon/saxon

/**
 * Prepare (compile) an XSLT pattern for subsequent evaluation. The result is an XPathExpression
 * object representing a (pseudo-) expression that when evaluated returns a boolean result: true
 * if the context node matches the pattern, false if it does not.
 * @param pattern the XSLT pattern to be compiled, supplied as a string
 * @return an XPathExpression object representing the pattern, wrapped as an expression
 * @throws XPathException if the syntax of the expression is wrong, or if it references namespaces,
 * variables, or functions that have not been declared.
 * @since 9.1
 */
public XPathExpression createPattern(String pattern) throws XPathException {
  Pattern pat = Pattern.make(pattern, staticContext, staticContext.getExecutable());
  ExpressionVisitor visitor = ExpressionVisitor.make(staticContext);
  pat.analyze(visitor, Type.NODE_TYPE);
  SlotManager map = staticContext.getStackFrameMap();
  int slots = map.getNumberOfVariables();
  slots = pat.allocateSlots(staticContext, map, slots);
  PatternSponsor sponsor = new PatternSponsor(pat);
  XPathExpression xpe = new XPathExpression(this, sponsor);
  xpe.setStackFrameMap(map, slots);
  return xpe;
}

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com