public class ChangeFactory extends Object
createChange(Element)
or
createChange(DocumentNode)
.
The annotations can be obtained using getAnnotaions()
(as
Apache/Jena RDF model), getRdfXml()
(encoded in RDF/XML),
printTtl()
(printed to sysout in TURTLE format), or
printXml()
(printed to sysout in RDF/XML format).Modifier and Type | Field and Description |
---|---|
static String |
COMODI_NS
The namespace of COMODI.
|
static String |
RDF_NS
The RDF namespace.
|
Constructor and Description |
---|
ChangeFactory(URI baseUri)
The Constructor specifying the base URI of the file containing the changes.
|
Modifier and Type | Method and Description |
---|---|
Change |
createChange(de.unirostock.sems.xmlutils.ds.DocumentNode node)
Creates a change encoded in the
DocumentNode element
node . |
Change |
createChange(org.jdom2.Element node)
Creates a change encoded in the JDOM element
node . |
org.apache.jena.rdf.model.Model |
getAnnotaions()
Gets the annotations.
|
int |
getNumChanges()
Gets the number changes produced by this factory.
|
int |
getNumStatements()
Gets the number of overall statements in all changes produced by this
change factory.
|
String |
getRdfXml()
Compiles the assembled changes in an RDF/XML string.
|
void |
printTtl()
Prints the TURTLE serialisation to sysout.
|
void |
printXml()
Prints the RDF/XML serialisation to sysout.
|
public static final String RDF_NS
public static final String COMODI_NS
public ChangeFactory(URI baseUri)
baseUri
- the URI of the file containing the changes we'll be talking aboutpublic int getNumStatements()
public int getNumChanges()
public Change createChange(org.jdom2.Element node)
node
.
node
is supposed to have an id
attribute.node
- the node encoding for the changepublic Change createChange(de.unirostock.sems.xmlutils.ds.DocumentNode node)
DocumentNode
element
node
. node
is supposed to have an id-attribute.node
- the node encoding for the changeDocumentNode
public String getRdfXml()
public org.apache.jena.rdf.model.Model getAnnotaions()
public void printTtl()
public void printXml()
Copyright © 2015 SEMS project @ University of Rostock. All rights reserved.