Search in sources :

Example 1 with PropertyFunctionRegistry

use of org.apache.jena.sparql.pfunction.PropertyFunctionRegistry in project jena by apache.

the class PathLib method install.

/** Install a path as a property function in a given registry */
public static void install(String uri, final Path path, PropertyFunctionRegistry registry) {
    PropertyFunctionFactory pathPropFuncFactory = (u) -> new PathPropertyFunction(path);
    registry.put(uri, pathPropFuncFactory);
}
Also used : Context(org.apache.jena.sparql.util.Context) Binding(org.apache.jena.sparql.engine.binding.Binding) ARQInternalErrorException(org.apache.jena.sparql.ARQInternalErrorException) BasicPattern(org.apache.jena.sparql.core.BasicPattern) QueryIterConcat(org.apache.jena.sparql.engine.iterator.QueryIterConcat) TriplePath(org.apache.jena.sparql.core.TriplePath) OpPath(org.apache.jena.sparql.algebra.op.OpPath) OpSequence(org.apache.jena.sparql.algebra.op.OpSequence) Graph(org.apache.jena.graph.Graph) ArrayList(java.util.ArrayList) QueryIterator(org.apache.jena.sparql.engine.QueryIterator) QueryIterYieldN(org.apache.jena.sparql.engine.iterator.QueryIterYieldN) Op(org.apache.jena.sparql.algebra.Op) GraphUtils(org.apache.jena.sparql.util.graph.GraphUtils) Iter(org.apache.jena.atlas.iterator.Iter) ExecutionContext(org.apache.jena.sparql.engine.ExecutionContext) BindingFactory(org.apache.jena.sparql.engine.binding.BindingFactory) PathEval(org.apache.jena.sparql.path.eval.PathEval) Iterator(java.util.Iterator) Predicate(java.util.function.Predicate) Triple(org.apache.jena.graph.Triple) QueryIterPlainWrapper(org.apache.jena.sparql.engine.iterator.QueryIterPlainWrapper) PropertyFunctionFactory(org.apache.jena.sparql.pfunction.PropertyFunctionFactory) PathBlock(org.apache.jena.sparql.core.PathBlock) Objects(java.util.Objects) List(java.util.List) Explain(org.apache.jena.sparql.mgt.Explain) Var(org.apache.jena.sparql.core.Var) Node(org.apache.jena.graph.Node) OpBGP(org.apache.jena.sparql.algebra.op.OpBGP) PropertyFunctionRegistry(org.apache.jena.sparql.pfunction.PropertyFunctionRegistry) PropertyFunctionFactory(org.apache.jena.sparql.pfunction.PropertyFunctionFactory)

Aggregations

ArrayList (java.util.ArrayList)1 Iterator (java.util.Iterator)1 List (java.util.List)1 Objects (java.util.Objects)1 Predicate (java.util.function.Predicate)1 Iter (org.apache.jena.atlas.iterator.Iter)1 Graph (org.apache.jena.graph.Graph)1 Node (org.apache.jena.graph.Node)1 Triple (org.apache.jena.graph.Triple)1 ARQInternalErrorException (org.apache.jena.sparql.ARQInternalErrorException)1 Op (org.apache.jena.sparql.algebra.Op)1 OpBGP (org.apache.jena.sparql.algebra.op.OpBGP)1 OpPath (org.apache.jena.sparql.algebra.op.OpPath)1 OpSequence (org.apache.jena.sparql.algebra.op.OpSequence)1 BasicPattern (org.apache.jena.sparql.core.BasicPattern)1 PathBlock (org.apache.jena.sparql.core.PathBlock)1 TriplePath (org.apache.jena.sparql.core.TriplePath)1 Var (org.apache.jena.sparql.core.Var)1 ExecutionContext (org.apache.jena.sparql.engine.ExecutionContext)1 QueryIterator (org.apache.jena.sparql.engine.QueryIterator)1