|
Restlet Framework 2.2.1 Java Standard Edition |
|||||||||
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.ChannelRepresentation
public abstract class ChannelRepresentation
Representation based on a NIO byte channel.
Field Summary |
---|
Fields inherited from class org.restlet.representation.Representation |
---|
UNKNOWN_SIZE |
Constructor Summary | |
---|---|
ChannelRepresentation(MediaType mediaType)
Constructor. |
Method Summary | |
---|---|
Reader |
getReader()
Returns a characters reader with the representation's content. |
InputStream |
getStream()
Returns a stream with the representation's content. |
void |
write(OutputStream outputStream)
Writes the representation to a byte stream. |
void |
write(Writer writer)
Writes the representation to a characters writer. |
Methods inherited from class org.restlet.representation.Representation |
---|
append, exhaust, getAvailableSize, getChannel, getDigest, getDisposition, getExpirationDate, getRange, getRegistration, getSize, getText, hasKnownSize, isAvailable, isEmpty, isSelectable, isTransient, release, setAvailable, setDigest, setDisposition, setExpirationDate, setListener, setRange, setSize, setTransient, write |
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 ChannelRepresentation(MediaType mediaType)
mediaType
- The media type.Method Detail |
---|
public Reader getReader() throws IOException
Representation
getReader
in class Representation
IOException
public InputStream getStream() throws IOException
Representation
getStream
in class Representation
IOException
public void write(OutputStream outputStream) throws IOException
Representation
OutputStream
after writing to it as this will be handled by
the Restlet connectors automatically.
write
in class Representation
outputStream
- The output stream.
IOException
public void write(Writer writer) throws IOException
Representation
Writer
after writing to it as this will be handled
by the Restlet connectors automatically.
write
in class Representation
writer
- The characters writer.
IOException
|
Restlet Framework 2.2.1 Java Standard Edition |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |