public class DefaultIRIHandler extends Object implements IRIHandler
IRIHandler
.Modifier and Type | Field and Description |
---|---|
protected static String |
DITAIDPREFIX |
Constructor and Description |
---|
DefaultIRIHandler() |
Modifier and Type | Method and Description |
---|---|
protected String |
encode(String part) |
String |
getDocumentOrTopicIRI(ToCNode node)
The IRI of topic and maps follows the scheme "urn:ditaid:" ":"
<id of topic or map> ":" <hash of content preprocessed by
DITA-OT>.
|
String |
getInfoObjectIRI(ToCNode node)
The IRI of information objects follows the scheme "urn:ditaid:" ":"
<id of topic or map>.
|
String |
getMetadataIRI(ToCNode node,
String classURI,
String label,
String context)
Generate IRI for a a metadata string property.
|
String |
getName()
The unique name of this IRI provider
|
String |
getPackageIRI(ToCNode root)
The IRI of a package is freshly generated UUID.
|
String |
toString() |
protected static final String DITAIDPREFIX
public String getName()
IRIHandler
getName
in interface IRIHandler
public String getInfoObjectIRI(ToCNode node)
getInfoObjectIRI
in interface IRIHandler
node
- the node for which to generatedpublic String getMetadataIRI(ToCNode node, String classURI, String label, String context)
IRIHandler
getMetadataIRI
in interface IRIHandler
node
- the node the metadata belongs toclassURI
- the URI of the RDF metadata classlabel
- something like a label of metadata valuecontext
- an additional context, usually the property name at the node
hinting the source of the metadata valuepublic String getDocumentOrTopicIRI(ToCNode node)
getDocumentOrTopicIRI
in interface IRIHandler
node
- the node for which to generatedToCNode.getContentHash()
public String getPackageIRI(ToCNode root)
getPackageIRI
in interface IRIHandler
root
- the node for which to generated (usually the root node)IRIUtils.generateUniqueIRI()
Copyright © 2024. All rights reserved.