@Deprecated public abstract class WritableRepresentation extends ChannelRepresentation
UNKNOWN_SIZE| Constructor and Description |
|---|
WritableRepresentation(MediaType mediaType)
Deprecated.
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
ReadableByteChannel |
getChannel()
Deprecated.
Returns a channel with the representation's content.
If it is supported by a file, a read-only instance of FileChannel is returned. This method is ensured to return a fresh channel for each invocation unless it is a transient representation, in which case null is returned. |
abstract void |
write(WritableByteChannel writableChannel)
Deprecated.
Writes the representation to a byte channel.
|
getReader, 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, hashCode, includes, isCompatible, setCharacterSet, setEncodings, setLanguages, setLocationRef, setLocationRef, setMediaType, toStringpublic WritableRepresentation(MediaType mediaType)
mediaType - The representation's media type.public ReadableByteChannel getChannel() throws IOException
RepresentationgetChannel in class RepresentationIOExceptionpublic abstract void write(WritableByteChannel writableChannel) throws IOException
Representationwrite in class RepresentationwritableChannel - A writable byte channel.IOExceptionCopyright © 2005–2025. All rights reserved.