public interface LiveWebCache
Modifier and Type | Method and Description |
---|---|
Resource |
getCachedResource(URL url,
long maxCacheMS,
boolean bUseOlder)
Fetch a Resource from the live web, or from a cache of the live web.
|
void |
shutdown()
closes all resources
|
Resource getCachedResource(URL url, long maxCacheMS, boolean bUseOlder) throws LiveDocumentNotAvailableException, LiveWebCacheUnavailableException, LiveWebTimeoutException, IOException
url
- to fetch from the live web.maxCacheMS
- maximum age of resource to return - optionally honoredbUseOlder
- if true, return documents older than maxCacheMS if
a more recent copy is not available.LiveDocumentNotAvailableException
- if the resource cannot be
retrieved from the live web, but all proxying and caching
mechanisms functioned properlyLiveWebCacheUnavailableException
- if there was a problem either
accessing the live web, in proxying to the live web, or in
maintaining the cache for the live webLiveWebTimeoutException
- if there is no response from the live
web cache before a timeout occurred.IOException
- for the usual reasonsvoid shutdown()
Copyright © 2005–2015 IIPC. All rights reserved.