org.archive.wayback.liveweb
Interface LiveWebCache

All Known Implementing Classes:
RemoteLiveWebCache

public interface LiveWebCache

Interface to retrieve Resource objects from the live web.

Version:
$Date: 2010-09-29 05:28:38 +0700 (Wed, 29 Sep 2010) $, $Revision: 3262 $
Author:
brad

Method Summary
 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
 

Method Detail

getCachedResource

Resource getCachedResource(URL url,
                           long maxCacheMS,
                           boolean bUseOlder)
                           throws LiveDocumentNotAvailableException,
                                  LiveWebCacheUnavailableException,
                                  IOException
Fetch a Resource from the live web, or from a cache of the live web.

Parameters:
url - to fetch from the live web.
maxCacheMS - maximum age of resource to return - optionally honored
bUseOlder - if true, return documents older than maxCacheMS if a more recent copy is not available.
Returns:
Resource for url
Throws:
LiveDocumentNotAvailableException - if the resource cannot be retrieved from the live web, but all proxying and caching mechanisms functioned properly
LiveWebCacheUnavailableException - if there was a problem either accessing the live web, in proxying to the live web, or in maintaining the cache for the live web
IOException - for the usual reasons

shutdown

void shutdown()
closes all resources



Copyright © 2005-2011 Internet Archive. All Rights Reserved.