java.lang.Object
org.apache.jena.sparql.graph.PrefixMappingBase
- All Implemented Interfaces:
org.apache.jena.shared.PrefixMapping
- Direct Known Subclasses:
BufferingPrefixMapping
,PrefixMappingAdapter
,PrefixMappingMem
,PrefixMappingSink
public abstract class PrefixMappingBase
extends Object
implements org.apache.jena.shared.PrefixMapping
Framework for implementing
PrefixMapping
. It is stateless (unlike
PrefixMappingImpl
) and implements the contract of PrefixMapping
,
providing the key algorithm and delegating storage to the subclasses.
Reverse mapping, looking up a URI to find a prefix is complex because there may be several possibilities. Applications should not rely on every implementation being consistent when there is a choice of which prefix to use to shorten a URI.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.jena.shared.PrefixMapping
org.apache.jena.shared.PrefixMapping.Factory, org.apache.jena.shared.PrefixMapping.IllegalPrefixException, org.apache.jena.shared.PrefixMapping.JenaLockedException
-
Field Summary
Fields inherited from interface org.apache.jena.shared.PrefixMapping
Extended, Standard
-
Method Summary
Modifier and TypeMethodDescriptionorg.apache.jena.shared.PrefixMapping
expandPrefix
(String prefixed) getNsPrefixURI
(String prefix) getNsURIPrefix
(String uri) boolean
org.apache.jena.shared.PrefixMapping
lock()
int
org.apache.jena.shared.PrefixMapping
removeNsPrefix
(String prefix) boolean
samePrefixMappingAs
(org.apache.jena.shared.PrefixMapping other) org.apache.jena.shared.PrefixMapping
setNsPrefix
(String prefix, String uri) org.apache.jena.shared.PrefixMapping
setNsPrefixes
(Map<String, String> map) org.apache.jena.shared.PrefixMapping
setNsPrefixes
(org.apache.jena.shared.PrefixMapping pmap) toString()
org.apache.jena.shared.PrefixMapping
withDefaultMappings
(org.apache.jena.shared.PrefixMapping pmap)
-
Method Details
-
setNsPrefix
- Specified by:
setNsPrefix
in interfaceorg.apache.jena.shared.PrefixMapping
-
removeNsPrefix
- Specified by:
removeNsPrefix
in interfaceorg.apache.jena.shared.PrefixMapping
-
clearNsPrefixMap
public org.apache.jena.shared.PrefixMapping clearNsPrefixMap()- Specified by:
clearNsPrefixMap
in interfaceorg.apache.jena.shared.PrefixMapping
-
setNsPrefixes
- Specified by:
setNsPrefixes
in interfaceorg.apache.jena.shared.PrefixMapping
-
getNsPrefixURI
- Specified by:
getNsPrefixURI
in interfaceorg.apache.jena.shared.PrefixMapping
-
getNsURIPrefix
- Specified by:
getNsURIPrefix
in interfaceorg.apache.jena.shared.PrefixMapping
-
getNsPrefixMap
- Specified by:
getNsPrefixMap
in interfaceorg.apache.jena.shared.PrefixMapping
-
expandPrefix
- Specified by:
expandPrefix
in interfaceorg.apache.jena.shared.PrefixMapping
-
qnameFor
- Specified by:
qnameFor
in interfaceorg.apache.jena.shared.PrefixMapping
-
shortForm
- Specified by:
shortForm
in interfaceorg.apache.jena.shared.PrefixMapping
-
lock
public org.apache.jena.shared.PrefixMapping lock()- Specified by:
lock
in interfaceorg.apache.jena.shared.PrefixMapping
-
hasNoMappings
public boolean hasNoMappings()- Specified by:
hasNoMappings
in interfaceorg.apache.jena.shared.PrefixMapping
-
numPrefixes
public int numPrefixes()- Specified by:
numPrefixes
in interfaceorg.apache.jena.shared.PrefixMapping
-
toString
-