gpt4 book ai didi

net.sf.saxon.query.XQueryFunction.getResultType()方法的使用及代码示例

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

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

XQueryFunction.getResultType介绍

[英]Get the result type of the function
[中]获取函数的结果类型

代码示例

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

/**
 * Check that all the types used in the signature of an imported function
 * are available in the module of the caller of the function
 * @param fd the declaration of the imported function
 * @throws XPathException if an error is found
 */
public void checkImportedFunctionSignature(XQueryFunction fd) throws XPathException {
  checkImportedType(fd.getResultType(), fd);
  for (int a=0; a<fd.getNumberOfArguments(); a++) {
    SequenceType argType = fd.getArgumentTypes()[a];
    checkImportedType(argType, fd);
  }
}

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

/**
 * Check that all the types used in the signature of an imported function
 * are available in the module of the caller of the function
 * @param fd the declaration of the imported function
 * @throws XPathException if an error is found
 */
public void checkImportedFunctionSignature(XQueryFunction fd) throws XPathException {
  checkImportedType(fd.getResultType(), fd);
  for (int a=0; a<fd.getNumberOfArguments(); a++) {
    SequenceType argType = fd.getArgumentTypes()[a];
    checkImportedType(argType, fd);
  }
}

代码示例来源:origin: net.sf.saxon/Saxon-HE

if (fd != null) {
  fd.registerReference(ufc);
  ufc.setStaticType(fd.getResultType());
} else {
  StringBuilder sb = new StringBuilder("Cannot find a " + arity +

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.saxon

if (fd != null) {
  fd.registerReference(ufc);
  ufc.setStaticType(fd.getResultType());
} else {
  StringBuilder sb = new StringBuilder("Cannot find a " + arity +

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

if (fd != null) {
  fd.registerReference(ufc);
  ufc.setStaticType(fd.getResultType());
  ufc.setConfirmed(true);

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

if (fd != null) {
  fd.registerReference(ufc);
  ufc.setStaticType(fd.getResultType());
  ufc.setConfirmed(true);

代码示例来源:origin: msokolov/lux

private FunctionDefinition[] getFunctionDefinitions() {
  ArrayList<FunctionDefinition> functionDefinitions = new ArrayList<FunctionDefinition>();
  Iterator<XQueryFunction> functions = queryModule.getLocalFunctionLibrary().getFunctionDefinitions();
  while (functions.hasNext()) {
    XQueryFunction function = functions.next();
    UserFunctionParameter[] params = function.getParameterDefinitions();
    Variable[] args = new Variable[params.length];
    for (int i = 0; i < params.length; i++) {
      QName argname = qnameFor (params[i].getVariableQName());
      addNamespaceDeclaration(argname);
      args[i] = new Variable (argname, getTypeDescription(params[i].getRequiredType()));
    }
    QName fname = qnameFor(function.getFunctionName());
    addNamespaceDeclaration(fname);
    SequenceType resultType = function.getResultType();
    ItemType returnType = resultType.getPrimaryType();
    QName returnTypeName = null;
    if (returnType instanceof NameTest) {
      returnTypeName = qnameForNameCode (((NameTest) returnType).getFingerprint());
    }
    FunctionDefinition fdef = new FunctionDefinition(fname, 
        valueTypeForItemType(resultType.getPrimaryType()), 
        cardinalityOf(resultType), returnTypeName,  
        args, exprFor (function.getBody()));  
    functionDefinitions.add (fdef);
  }
  return functionDefinitions.toArray(new FunctionDefinition[0]);
}

代码示例来源:origin: net.sf.saxon/Saxon-HE

ufc.setFunctionName(fd.getFunctionName());
ufc.setArguments(arguments);
ufc.setStaticType(fd.getResultType());
UserFunction fn = fd.getUserFunction();
if (fn == null) {

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.saxon

ufc.setFunctionName(fd.getFunctionName());
ufc.setArguments(arguments);
ufc.setStaticType(fd.getResultType());
UserFunction fn = fd.getUserFunction();
if (fn == null) {

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

ufc.setFunctionName(fd.getFunctionName());
ufc.setArguments(arguments);
ufc.setStaticType(fd.getResultType());
UserFunction fn = fd.getUserFunction();
if (fn == null) {

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

ufc.setFunctionName(fd.getFunctionName());
ufc.setArguments(arguments);
ufc.setStaticType(fd.getResultType());
UserFunction fn = fd.getUserFunction();
if (fn == null) {

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

compiledFunction.setFunctionName(functionName);
compiledFunction.setParameterDefinitions(params);
compiledFunction.setResultType(getResultType());
compiledFunction.setLineNumber(lineNumber);
compiledFunction.setSystemId(systemId);

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

compiledFunction.setFunctionName(functionName);
compiledFunction.setParameterDefinitions(params);
compiledFunction.setResultType(getResultType());
compiledFunction.setLineNumber(lineNumber);
compiledFunction.setSystemId(systemId);

代码示例来源:origin: net.sf.saxon/Saxon-HE

compiledFunction.setFunctionName(functionName);
compiledFunction.setParameterDefinitions(params);
compiledFunction.setResultType(getResultType());
compiledFunction.setLineNumber(location.getLineNumber());
compiledFunction.setSystemId(location.getSystemId());

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.saxon

compiledFunction.setFunctionName(functionName);
compiledFunction.setParameterDefinitions(params);
compiledFunction.setResultType(getResultType());
compiledFunction.setLineNumber(location.getLineNumber());
compiledFunction.setSystemId(location.getSystemId());

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