public class RdfRepresentation extends WriterRepresentation
Graph.UNKNOWN_SIZE| Constructor and Description |
|---|
RdfRepresentation()
Constructor.
|
RdfRepresentation(Graph linkSet,
MediaType mediaType)
Constructor with argument.
|
RdfRepresentation(MediaType mediaType)
Constructor with argument.
|
RdfRepresentation(Representation rdfRepresentation)
Constructor that parsed a given RDF representation into a link set.
|
| Modifier and Type | Method and Description |
|---|---|
GraphHandler |
createBuilder(Graph graph)
Returns an instance of a graph handler used when parsing the inner RDF
representation.
|
GraphHandler |
createWriter(MediaType mediaType,
Writer writer)
Returns an instance of a graph handler used when writing the inner set of
links.
|
Graph |
getGraph()
Returns the graph of links.
|
void |
parse(GraphHandler graphHandler)
Parses the inner RDF representation.
|
void |
setGraph(Graph linkSet)
Sets the graph of links.
|
void |
write(GraphHandler graphHandler)
Writes the
|
void |
write(Writer writer)
Writes the representation to a characters writer.
|
getReadergetChannel, getStream, write, writeappend, exhaust, getAvailableSize, getDigest, getDisposition, getExpirationDate, getRange, getRegistration, getSize, getText, hasKnownSize, isAvailable, isEmpty, isSelectable, isTransient, release, setAvailable, setDigest, setDisposition, setExpirationDate, setListener, setRange, setSize, setTransientgetModificationDate, getTag, setModificationDate, setTagcreateClientInfo, equals, getCharacterSet, getEncodings, getLanguages, getLocationRef, getMediaType, includes, isCompatible, setCharacterSet, setEncodings, setLanguages, setLocationRef, setLocationRef, setMediaType, toStringpublic RdfRepresentation()
public RdfRepresentation(Graph linkSet, MediaType mediaType)
linkSet - The graph of links.mediaType - The representation's mediaType.public RdfRepresentation(MediaType mediaType)
mediaType - The representation's mediaType.public RdfRepresentation(Representation rdfRepresentation) throws IOException
rdfRepresentation - The RDF representation to parse.IOExceptionpublic GraphHandler createBuilder(Graph graph)
graph - The graph to build.public GraphHandler createWriter(MediaType mediaType, Writer writer) throws IOException
mediaType - The given media type of the parsed RDF representation.writer - The character writer to write to.IOExceptionpublic Graph getGraph() throws IOException
IOExceptionpublic void parse(GraphHandler graphHandler) throws IOException
graphHandler - The graph handler.IOExceptionpublic void setGraph(Graph linkSet)
linkSet - The graph of links.public void write(GraphHandler graphHandler) throws IOException
graphHandler - IOExceptionpublic void write(Writer writer) throws IOException
RepresentationWriter after writing to it as this will be handled
by the Restlet connectors automatically.write in class Representationwriter - The characters writer.IOExceptionCopyright © 2005–2015. All rights reserved.