public class TriXWriter extends AbstractRDFWriter implements RDFWriter
namespaceTable, statementConsumer| Modifier | Constructor and Description |
|---|---|
|
TriXWriter(OutputStream out)
Creates a new TriXWriter that will write to the supplied OutputStream.
|
|
TriXWriter(Writer writer)
Creates a new TriXWriter that will write to the supplied Writer.
|
protected |
TriXWriter(XMLWriter xmlWriter) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
consumeStatement(Statement st)
Consume a statement.
|
void |
endRDF()
Signals the end of the RDF data.
|
RDFFormat |
getRDFFormat()
Gets the RDF format that this RDFWriter uses.
|
void |
handleComment(String comment)
Handles a comment.
|
void |
handleNamespace(String prefix,
String name)
Handles a namespace declaration/definition.
|
void |
startRDF()
Signals the start of the RDF data.
|
checkWritingStarted, getOutputStream, getSupportedSettings, getWriterConfig, handleStatement, isWritingStarted, set, setWriterConfigclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetOutputStream, getSupportedSettings, getWriterConfig, set, setWriterConfighandleStatementpublic TriXWriter(OutputStream out)
out - The OutputStream to write the RDF/XML document to.public TriXWriter(Writer writer)
writer - The Writer to write the RDF/XML document to.protected TriXWriter(XMLWriter xmlWriter)
public RDFFormat getRDFFormat()
RDFWritergetRDFFormat in interface RDFWriterpublic void startRDF()
throws RDFHandlerException
RDFHandlerstartRDF in interface RDFHandlerstartRDF in class AbstractRDFWriterRDFHandlerException - If the RDF handler has encountered an unrecoverable error.public void endRDF()
throws RDFHandlerException
RDFHandlerendRDF in interface RDFHandlerRDFHandlerException - If the RDF handler has encountered an unrecoverable error.public void handleNamespace(String prefix, String name)
RDFHandlerhandleNamespace in interface RDFHandlerhandleNamespace in class AbstractRDFWriterprefix - The prefix for the namespace, or an empty string in case of a default namespace.name - The URI that the prefix maps to.protected void consumeStatement(Statement st)
AbstractRDFWriterAbstractRDFWriter.handleStatement(Statement) in order to
benefit from automatic handling of RDF* conversion or encoding.consumeStatement in class AbstractRDFWriterst - the statement to consume.public void handleComment(String comment) throws RDFHandlerException
RDFHandlerhandleComment in interface RDFHandlercomment - The comment.RDFHandlerException - If the RDF handler has encountered an unrecoverable error.Copyright © 2015-2020 Eclipse Foundation. All Rights Reserved.