|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.restlet.representation.Variant
org.restlet.representation.RepresentationInfo
org.restlet.representation.Representation
org.restlet.representation.CharacterRepresentation
org.restlet.representation.WriterRepresentation
org.restlet.ext.rdf.RdfRepresentation
public class RdfRepresentation
Generic RDF representation. Provides support for the Resource Description
Framework (RDF) Semantic Web standard. It supports major RDF serialization
formats (n3, Turtle, N-Triples and RDF/XML) and is able to both serialize and
deserialize a Graph
.
Field Summary |
---|
Fields inherited from class org.restlet.representation.Representation |
---|
UNKNOWN_SIZE |
Constructor Summary | |
---|---|
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. |
Method Summary | |
---|---|
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)
|
Methods inherited from class org.restlet.representation.WriterRepresentation |
---|
getReader |
Methods inherited from class org.restlet.representation.CharacterRepresentation |
---|
getChannel, getStream, write, write |
Methods inherited from class org.restlet.representation.Representation |
---|
append, exhaust, getAvailableSize, getDigest, getDisposition, getExpirationDate, getRange, getRegistration, getSize, getText, hasKnownSize, isAvailable, isEmpty, isSelectable, isTransient, release, setAvailable, setDigest, setDisposition, setExpirationDate, setListener, setRange, setSize, setTransient |
Methods inherited from class org.restlet.representation.RepresentationInfo |
---|
getModificationDate, getTag, setModificationDate, setTag |
Methods inherited from class org.restlet.representation.Variant |
---|
createClientInfo, equals, getCharacterSet, getEncodings, getLanguages, getLocationRef, getMediaType, includes, isCompatible, setCharacterSet, setEncodings, setLanguages, setLocationRef, setLocationRef, setMediaType, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public 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.
IOException
Method Detail |
---|
public 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.
IOException
public Graph getGraph() throws IOException
IOException
public void parse(GraphHandler graphHandler) throws IOException
graphHandler
- The graph handler.
IOException
public void setGraph(Graph linkSet)
linkSet
- The graph of links.public void write(GraphHandler graphHandler) throws IOException
graphHandler
-
IOException
public void write(Writer writer) throws IOException
write
in class Representation
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |