|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.tapestry5.internal.services.assets.StreamableResourceImpl
public class StreamableResourceImpl
| Constructor Summary | |
|---|---|
StreamableResourceImpl(String description,
String contentType,
CompressionStatus compression,
long lastModified,
BytestreamCache bytestreamCache)
|
|
| Method Summary | |
|---|---|
CompressionStatus |
getCompression()
Indicates if the content is compressed, or compressable. |
String |
getContentType()
Returns the MIME content type, e.g., "image/jpeg". |
String |
getDescription()
Describes the underlying Resource (or resources} for this streamble resource; expressly used
as part of the object's toString(). |
long |
getLastModified()
Returns the time the resource was last modified, with accuracy to one second (so as to match the HTTP request/response date headers. |
int |
getSize()
The size, in bytes, of the underlying bytestream. |
InputStream |
openStream()
Opens the content of the resource as an input stream; the caller is responsible for closing the stream after reading it. |
void |
streamTo(OutputStream os)
Streams the resource's content to the provided stream. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public StreamableResourceImpl(String description,
String contentType,
CompressionStatus compression,
long lastModified,
BytestreamCache bytestreamCache)
| Method Detail |
|---|
public String getDescription()
StreamableResourceResource (or resources} for this streamble resource; expressly used
as part of the object's toString().
getDescription in interface StreamableResourcepublic CompressionStatus getCompression()
StreamableResource
getCompression in interface StreamableResourcepublic String getContentType()
StreamableResource
getContentType in interface StreamableResourcepublic int getSize()
StreamableResource
getSize in interface StreamableResourcepublic long getLastModified()
StreamableResource
getLastModified in interface StreamableResource
public void streamTo(OutputStream os)
throws IOException
StreamableResource
streamTo in interface StreamableResourceIOException
public InputStream openStream()
throws IOException
StreamableResource
openStream in interface StreamableResourceIOExceptionpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||