public class PropertyConverter extends com.google.common.base.Converter<javax.jcr.Property,org.apache.jena.rdf.model.Property>
Constructor and Description |
---|
PropertyConverter() |
Modifier and Type | Method and Description |
---|---|
protected javax.jcr.Property |
doBackward(org.apache.jena.rdf.model.Property property) |
protected org.apache.jena.rdf.model.Property |
doForward(javax.jcr.Property property) |
static String |
getPropertyNameFromPredicate(org.modeshape.jcr.api.NamespaceRegistry namespaceRegistry,
org.apache.jena.rdf.model.Resource predicate,
Map<String,String> namespaceMapping)
Get the JCR property name for an RDF predicate
|
static String |
getPropertyNameFromPredicate(javax.jcr.Node node,
org.apache.jena.rdf.model.Resource predicate,
Map<String,String> namespaceMapping)
Given an RDF predicate value (namespace URI + local name), figure out
what JCR property to use
|
public PropertyConverter()
protected org.apache.jena.rdf.model.Property doForward(javax.jcr.Property property)
doForward
in class com.google.common.base.Converter<javax.jcr.Property,org.apache.jena.rdf.model.Property>
protected javax.jcr.Property doBackward(org.apache.jena.rdf.model.Property property)
doBackward
in class com.google.common.base.Converter<javax.jcr.Property,org.apache.jena.rdf.model.Property>
public static String getPropertyNameFromPredicate(javax.jcr.Node node, org.apache.jena.rdf.model.Resource predicate, Map<String,String> namespaceMapping) throws javax.jcr.RepositoryException
node
- the JCR node we want a property forpredicate
- the predicate to map to a property namenamespaceMapping
- prefix to uri namespace mappingjavax.jcr.RepositoryException
- if repository exception occurredpublic static String getPropertyNameFromPredicate(org.modeshape.jcr.api.NamespaceRegistry namespaceRegistry, org.apache.jena.rdf.model.Resource predicate, Map<String,String> namespaceMapping) throws javax.jcr.RepositoryException
namespaceRegistry
- the namespace registrypredicate
- the predicate to map to a property namenamespaceMapping
- the namespace mappingjavax.jcr.RepositoryException
- if repository exception occurredCopyright © 2013–2017 DuraSpace, Inc.. All rights reserved.