| java.lang.Object uk.org.ponder.springutil.CachingInputStreamSource
CachingInputStreamSource | public class CachingInputStreamSource implements StreamResolver(Code) | | A "caching" source of InputStreams that will only poll the filesystem for
changes after a specified lag. Currently any non-filesystem resources are
assumed to be ALWAYS STALE, that is, they will always have their streams
returned rather than the marker.
author: Antranig Basman (antranig@caret.cam.ac.uk) |
Field Summary | |
final public static int | ALWAYS_STALE | final public static long | NEVER_STALE_MODTIME | final public static InputStream | UP_TO_DATE If the stream is considered up to date, either through actually being up to
date or through having been polled within the last
cacheSeconds , this marker value is returned from
getInputStream. |
ALWAYS_STALE | final public static int ALWAYS_STALE(Code) | | |
NEVER_STALE_MODTIME | final public static long NEVER_STALE_MODTIME(Code) | | |
UP_TO_DATE | final public static InputStream UP_TO_DATE(Code) | | If the stream is considered up to date, either through actually being up to
date or through having been polled within the last
cacheSeconds , this marker value is returned from
getInputStream. Do not attempt to use any methods of this object!
|
CachingInputStreamSource | public CachingInputStreamSource(ResourceLoader resourceloader, int cachesecs)(Code) | | |
setCacheSeconds | public void setCacheSeconds(int cachesecs)(Code) | | Sets the lag after which the filesystem will be checked again for change of
datestamp. At a value of ALWAYS_STALE (0) the resource will always be
reloaded.
|
|
|