public class FileBackedHttpResource extends HttpResource
| コンストラクタと説明 |
|---|
FileBackedHttpResource(String resource,
String backingFile)
Constructor.
|
FileBackedHttpResource(String resource,
String backingFile,
ResourceFilter resourceFilter)
推奨されていません。
|
FileBackedHttpResource(String resource,
URI backingFile)
Constructor.
|
FileBackedHttpResource(String resource,
URI backingFile,
ResourceFilter resourceFilter)
推奨されていません。
|
| 修飾子とタイプ | メソッドと説明 |
|---|---|
boolean |
exists()
Checks whether the resource exists.
|
InputStream |
getInputStream()
Gets the inputstream to the resource's data.
|
org.joda.time.DateTime |
getLastModifiedTime()
Gets the date and time the resource was last modified.
|
String |
getLocation()
Gets resource location information.
|
protected void |
saveToResourceFile(byte[] resource)
Saves a resource to the backing file.
|
equals, getResource, hashCode, toStringapplyFilter, getResourceFilter, setResourceFilterpublic FileBackedHttpResource(String resource, String backingFile)
resource - HTTP(S) URL of the resourcebackingFile - filesystem location to store the resourcepublic FileBackedHttpResource(String resource, URI backingFile)
resource - HTTP(S) URL of the resourcebackingFile - file: URI location to store the resourcepublic FileBackedHttpResource(String resource, String backingFile, ResourceFilter resourceFilter)
AbstractFilteredResource.setResourceFilter(ResourceFilter) insteadresource - HTTP(S) URL of the resourcebackingFile - filesystem location to store the resourceresourceFilter - filter to apply to this resourcepublic FileBackedHttpResource(String resource, URI backingFile, ResourceFilter resourceFilter)
AbstractFilteredResource.setResourceFilter(ResourceFilter) insteadresource - HTTP(S) URL of the resourcebackingFile - filesystem location to store the resourceresourceFilter - filter to apply to this resourcepublic boolean exists()
throws ResourceException
exists インタフェース内 Resourceexists クラス内 HttpResourceResourceException - thrown if there is a problem determining if the resource existspublic InputStream getInputStream() throws ResourceException
getInputStream インタフェース内 ResourcegetInputStream クラス内 HttpResourceResourceException - thrown if an input stream can not be created for the resourcepublic org.joda.time.DateTime getLastModifiedTime()
throws ResourceException
getLastModifiedTime インタフェース内 ResourcegetLastModifiedTime クラス内 HttpResourceResourceException - thrown if the last modified time can not be determinedpublic String getLocation()
getLocation インタフェース内 ResourcegetLocation クラス内 HttpResourceprotected void saveToResourceFile(byte[] resource)
throws ResourceException
resource - the string representation of the resourceResourceException - thrown if the resource backing file can not be written toCopyright © 2012. All Rights Reserved.