|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.wicket.util.resource.AbstractResourceStream
org.apache.wicket.util.resource.FileResourceStream
public class FileResourceStream
A FileResourceStream is an IResource implementation for files.
IResourceStream,
IModifiable,
Serialized Form| Constructor Summary | |
|---|---|
FileResourceStream(File file)
Constructor. |
|
FileResourceStream(File file)
Constructor. |
|
| Method Summary | |
|---|---|
void |
close()
Closes this resource. |
String |
getContentType()
Gets the mime type of this resource |
File |
getFile()
|
InputStream |
getInputStream()
Gets the resource stream. |
Time |
lastModifiedTime()
Gets the last time this modifiable thing changed. |
Bytes |
length()
Gets the size of this resource |
String |
locationAsString()
|
String |
toString()
|
| Methods inherited from class org.apache.wicket.util.resource.AbstractResourceStream |
|---|
getLocale, getStyle, getVariation, setLocale, setStyle, setVariation |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public FileResourceStream(File file)
file - File containing resourcepublic FileResourceStream(File file)
file - File containing resource| Method Detail |
|---|
public void close()
throws IOException
close in interface Closeableclose in interface IResourceStreamIOExceptionpublic String getContentType()
IResourceStream
getContentType in interface IResourceStreamgetContentType in class AbstractResourceStreamResourceStreamRequestHandler handle the Content-Type automaticallyWebResponse#detectContentType(org.apache.wicket.RequestCycle, String)public File getFile()
public InputStream getInputStream()
throws ResourceStreamNotFoundException
IResourceStream
getInputStream in interface IResourceStreamResourceStreamNotFoundExceptionIResourceStream.close()public Time lastModifiedTime()
IModifiable
lastModifiedTime in interface IModifiablelastModifiedTime in class AbstractResourceStreamIModifiable.lastModifiedTime()public String toString()
toString in class Objectpublic Bytes length()
IResourceStream
length in interface IResourceStreamlength in class AbstractResourceStreamnull if unknownpublic String locationAsString()
locationAsString in interface IFixedLocationResourceStream
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||