|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.fuberlin.wiwiss.ng4j.trix.JenaRDFReaderWithExtensions
public class JenaRDFReaderWithExtensions
Simple RDFReader that adds support for the TriX syntax (see TriX specification) to the Jena framework. Does not support TriX's named graph features. It adds all statements from the first graph to a Jena model, ignoring its name if present, and ignoring all further graphs if present.
Constructor Summary | |
---|---|
JenaRDFReaderWithExtensions()
|
Method Summary | |
---|---|
void |
endGraph()
Called at the end of each trix:graph element |
void |
objectBNode(String id)
Called for each trix:triple element whose object is a trix:id. |
void |
objectPlainLiteral(String value,
String lang)
Called for each trix:triple element whose object is a trix:plainLiteral. |
void |
objectTypedLiteral(String value,
String datatypeURI)
Called for each trix:triple element whose object is a trix:typedLiteral. |
void |
objectURI(String uri)
Called for each trix:triple element whose object is a trix:uri. |
void |
predicate(String uri)
Called for the predicate of each trix:triple. |
void |
read(Model model,
InputStream r,
String base)
|
void |
read(Model model,
Reader r,
String base)
|
void |
read(Model model,
String url)
|
RDFErrorHandler |
setErrorHandler(RDFErrorHandler errHandler)
|
Object |
setProperty(String propName,
Object propValue)
|
void |
startGraph(List uris)
Called at the beginning of each trix:graph element. |
void |
subjectBNode(String id)
Called for each trix:triple element whose subject is a trix:id. |
void |
subjectPlainLiteral(String value,
String lang)
Called for each trix:triple element whose subject is a trix:plainLiteral. |
void |
subjectTypedLiteral(String value,
String datatypeURI)
Called for each trix:triple element whose subject is a trix:typedLiteral. |
void |
subjectURI(String uri)
Called for each trix:triple element whose subject is a trix:uri. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JenaRDFReaderWithExtensions()
Method Detail |
---|
public void read(Model model, Reader r, String base)
read
in interface RDFReader
public void read(Model model, InputStream r, String base)
read
in interface RDFReader
public void read(Model model, String url)
read
in interface RDFReader
public Object setProperty(String propName, Object propValue)
setProperty
in interface RDFReader
public RDFErrorHandler setErrorHandler(RDFErrorHandler errHandler)
setErrorHandler
in interface RDFReader
public void startGraph(List uris)
ParserCallback
startGraph
in interface ParserCallback
uris
- zero or more names of the graph, as stringspublic void endGraph()
ParserCallback
endGraph
in interface ParserCallback
public void subjectURI(String uri)
ParserCallback
subjectURI
in interface ParserCallback
uri
- the subject URI of the triplepublic void subjectBNode(String id)
ParserCallback
subjectBNode
in interface ParserCallback
id
- the subject blank node ID of the triplepublic void subjectPlainLiteral(String value, String lang)
ParserCallback
subjectPlainLiteral
in interface ParserCallback
value
- the subject literal value of the triplelang
- the language tag of the subject literal, or null
if none was givenpublic void subjectTypedLiteral(String value, String datatypeURI)
ParserCallback
subjectTypedLiteral
in interface ParserCallback
value
- the subject literal value of the tripledatatypeURI
- the datatype URI of the subject literalpublic void predicate(String uri)
ParserCallback
predicate
in interface ParserCallback
uri
- the predicate URI of the triple.public void objectURI(String uri)
ParserCallback
objectURI
in interface ParserCallback
uri
- the object URI of the triplepublic void objectBNode(String id)
ParserCallback
objectBNode
in interface ParserCallback
id
- the object blank node ID of the triplepublic void objectPlainLiteral(String value, String lang)
ParserCallback
objectPlainLiteral
in interface ParserCallback
value
- the object literal value of the triplelang
- the language tag of the object literal, or null
if none was givenpublic void objectTypedLiteral(String value, String datatypeURI)
ParserCallback
objectTypedLiteral
in interface ParserCallback
value
- the object literal value of the tripledatatypeURI
- the datatype URI of the object literal
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |