Class PathToRelationMapper<P>
java.lang.Object
org.aksw.jena_sparql_api.data_query.impl.PathToRelationMapper<P>
- Type Parameters:
P-
Stateful mapper that creates SPARQL BinaryRelation objects from paths,
thereby ensuring consistent variable naming
The mapper does not track changes - such as modifying a path's alias
TODO Here is the place for making use of a registry for mapping path elements to binary relations if desired ~ Claus Stadler, Jun 2, 2019
- Author:
- Claus Stadler, May 30, 2018
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Set<org.apache.jena.sparql.core.Var>protected PathAccessorRdf<P>protected org.aksw.commons.collections.generator.Generator<org.apache.jena.sparql.core.Var> -
Constructor Summary
ConstructorsConstructorDescriptionPathToRelationMapper(PathAccessorRdf<P> pathAccessor) PathToRelationMapper(PathAccessorRdf<P> pathAccessor, String baseName) PathToRelationMapper(PathAccessorRdf<P> pathAccessor, Map<P, Fragment2> map, Set<org.apache.jena.sparql.core.Var> forbiddenVars, org.aksw.commons.collections.generator.Generator<org.apache.jena.sparql.core.Var> varGen) -
Method Summary
Modifier and TypeMethodDescriptionstatic <P> org.apache.jena.sparql.graph.NodeTransformcreateNodeTransformSubstitutePathReferences(Function<? super org.apache.jena.graph.Node, ? extends P> tryMapToPath, Function<? super P, ? extends org.apache.jena.graph.Node> mapToNode) getMap()org.apache.jena.graph.NodegetOrCreate(P path) getOverallRelation(P path)
-
Field Details
-
pathAccessor
-
map
-
forbiddenVars
-
varGen
protected org.aksw.commons.collections.generator.Generator<org.apache.jena.sparql.core.Var> varGen
-
-
Constructor Details
-
PathToRelationMapper
-
PathToRelationMapper
-
PathToRelationMapper
-
-
Method Details
-
getMap
-
createNodeTransformSubstitutePathReferences
-
getPathAccessor
-
getNode
-
getOverallRelation
-
getOrCreate
-