public abstract class RDFRendererBase
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
RDFRendererBase.TripleComparator |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
GENERAL_AXIOMS_BANNER_TEXT |
protected OWLOntology |
ontology |
protected java.util.Set<IRI> |
prettyPrintedTypes |
static java.lang.String |
RULES_BANNER_TEXT |
static RDFRendererBase.TripleComparator |
tripleComparator |
Modifier | Constructor and Description |
---|---|
|
RDFRendererBase(OWLOntology ontology) |
protected |
RDFRendererBase(OWLOntology ontology,
OWLOntologyFormat format) |
|
RDFRendererBase(OWLOntology ontology,
OWLOntologyManager manager)
Deprecated.
|
protected |
RDFRendererBase(OWLOntology ontology,
OWLOntologyManager manager,
OWLOntologyFormat format)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
protected abstract void |
beginDocument()
Called before the ontology document is rendered.
|
protected void |
beginObject()
Called before an OWLObject such as an entity, anonymous individual, rule etc.
|
protected void |
createGraph(java.util.Set<? extends OWLObject> objects) |
protected abstract void |
endDocument()
Called after the ontology document has been rendered.
|
protected void |
endObject()
Called after an OWLObject such as an entity, anonymous individual, rule etc.
|
RDFGraph |
getGraph() |
OWLOntology |
getOntology() |
protected boolean |
isObjectList(RDFResourceNode node) |
void |
render() |
abstract void |
render(RDFResourceNode node)
Renders the triples in the current graph into a concrete format.
|
void |
renderAnonRoots() |
protected boolean |
shouldInsertDeclarations() |
protected void |
toJavaList(RDFNode n,
java.util.List<RDFNode> list) |
protected abstract void |
writeAnnotationPropertyComment(OWLAnnotationProperty prop)
Called before an annotation property is rendered to give subclasses the chance to prefix the rendering with
comments etc.
|
protected abstract void |
writeBanner(java.lang.String name) |
protected abstract void |
writeClassComment(OWLClass cls)
Called before a class is rendered to give subclasses the chance to prefix the rendering with comments etc.
|
protected abstract void |
writeDataPropertyComment(OWLDataProperty prop)
Called before a data property is rendered to give subclasses the chance to prefix the rendering with comments etc.
|
protected abstract void |
writeDatatypeComment(OWLDatatype datatype)
Called before a datatype is rendered to give subclasses the chance to prefix the rendering with comments etc.
|
protected abstract void |
writeIndividualComments(OWLNamedIndividual ind)
Called before an individual is rendered to give subclasses the chance to prefix the rendering with comments etc.
|
protected abstract void |
writeObjectPropertyComment(OWLObjectProperty prop)
Called before an object property is rendered.
|
public static final java.lang.String GENERAL_AXIOMS_BANNER_TEXT
public static final java.lang.String RULES_BANNER_TEXT
protected OWLOntology ontology
protected java.util.Set<IRI> prettyPrintedTypes
public static final RDFRendererBase.TripleComparator tripleComparator
public RDFRendererBase(OWLOntology ontology)
@Deprecated public RDFRendererBase(OWLOntology ontology, OWLOntologyManager manager)
@Deprecated protected RDFRendererBase(OWLOntology ontology, OWLOntologyManager manager, OWLOntologyFormat format)
protected RDFRendererBase(OWLOntology ontology, OWLOntologyFormat format)
public RDFGraph getGraph()
public OWLOntology getOntology()
protected abstract void beginDocument() throws java.io.IOException
java.io.IOException
- if there was a problem writing to the output streamprotected abstract void endDocument() throws java.io.IOException
java.io.IOException
- if there was a problem writing to the output streamprotected void beginObject() throws java.io.IOException
java.io.IOException
- if there was a problem writing to the output streamprotected void endObject() throws java.io.IOException
java.io.IOException
- if there was a problem writing to the output streamprotected abstract void writeAnnotationPropertyComment(OWLAnnotationProperty prop) throws java.io.IOException
prop
- The property being renderedjava.io.IOException
- if there was a problem writing to the output streamprotected abstract void writeDataPropertyComment(OWLDataProperty prop) throws java.io.IOException
prop
- The property being renderedjava.io.IOException
- if there was a problem writing to the output streamprotected abstract void writeObjectPropertyComment(OWLObjectProperty prop) throws java.io.IOException
prop
- The property being renderedjava.io.IOException
- if there was a problem writing to the output streamprotected abstract void writeClassComment(OWLClass cls) throws java.io.IOException
cls
- The class being renderedjava.io.IOException
- if there was a problem writing to the output streamprotected abstract void writeDatatypeComment(OWLDatatype datatype) throws java.io.IOException
datatype
- The datatype being renderedjava.io.IOException
- if there was a problem writing to the output streamprotected abstract void writeIndividualComments(OWLNamedIndividual ind) throws java.io.IOException
ind
- The individual being renderedjava.io.IOException
- if there was a problem writing to the output streampublic void render() throws java.io.IOException
java.io.IOException
protected boolean shouldInsertDeclarations()
protected void createGraph(java.util.Set<? extends OWLObject> objects)
protected abstract void writeBanner(java.lang.String name) throws java.io.IOException
java.io.IOException
public void renderAnonRoots() throws java.io.IOException
java.io.IOException
public abstract void render(RDFResourceNode node) throws java.io.IOException
node
- The main node to be renderedjava.io.IOException
- If there was a problem rendering the triples.protected boolean isObjectList(RDFResourceNode node)