本文整理了Java中org.apache.jena.query.Query.getValuesVariables
方法的一些代码示例,展示了Query.getValuesVariables
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Query.getValuesVariables
方法的具体详情如下:
包路径:org.apache.jena.query.Query
类名称:Query
方法名:getValuesVariables
[英]Variables from a VALUES trailing block
[中]值跟踪块中的变量
代码示例来源:origin: apache/jena
@Override
public void visitValues(Query query)
{
if ( query.hasValues() )
{
x ^= query.getValuesVariables().hashCode() ;
x ^= query.getValuesData().hashCode() ;
}
}
代码示例来源:origin: apache/jena
@Override
public void visitValues(Query query1)
{
// Must be same order for now.
check("VALUES/variables", query1.getValuesVariables(), query2.getValuesVariables()) ;
check("VALUES/values", query1.getValuesData(), query2.getValuesData()) ;
}
代码示例来源:origin: apache/jena
private static Collection<Var> varsOfQuery(Query query)
{
Collection<Var> vars = PatternVars.vars(query.getQueryPattern()) ;
if ( query.hasValues() )
vars.addAll(query.getValuesVariables()) ;
return vars ;
}
代码示例来源:origin: apache/jena
@Override
public void visitValues(Query query) {
if (query.hasValues())
newQuery.setValuesDataBlock(query.getValuesVariables(), query.getValuesData());
}
代码示例来源:origin: SmartDataAnalytics/jena-sparql-api
@Override
public void visitValues(Query query) {
if ( query.hasValues() )
newQuery.setValuesDataBlock(query.getValuesVariables(), query.getValuesData()) ;
}
代码示例来源:origin: apache/jena
private void findAndAddNamedVars()
{
Iterator<Var> varIter = null ;
if ( hasGroupBy() )
varIter = groupVars.getVars().iterator() ;
else
{
// Binding variables -- in patterns, not in filters and not in EXISTS
LinkedHashSet<Var> queryVars = new LinkedHashSet<>() ;
PatternVars.vars(queryVars, this.getQueryPattern()) ;
if ( this.hasValues() )
queryVars.addAll(getValuesVariables()) ;
// if ( this.hasValues() )
// queryVars.addAll(getValuesVariables()) ;
varIter = queryVars.iterator() ;
}
// All query variables, including ones from bNodes in the query.
for ( ; varIter.hasNext() ; )
{
Object obj = varIter.next() ;
//Var var = (Var)iter.next() ;
Var var = (Var)obj ;
if ( var.isNamedVar() )
addResultVar(var) ;
}
}
代码示例来源:origin: apache/jena
@Override
public void visitValues(Query query)
{
if ( query.hasValues() )
{
outputDataBlock(out, query.getValuesVariables(), query.getValuesData(), fmtElement.context) ;
out.newline() ;
}
}
代码示例来源:origin: apache/jena
Table table = TableFactory.create(query.getValuesVariables()) ;
for ( Binding binding : query.getValuesData() )
table.addBinding(binding) ;
内容来源于网络,如有侵权,请联系作者删除!