org.archive.wayback.archivalurl
Class ArchivalUrlDateRedirectReplayRenderer

java.lang.Object
  extended by org.archive.wayback.archivalurl.ArchivalUrlDateRedirectReplayRenderer
All Implemented Interfaces:
ReplayRenderer

public class ArchivalUrlDateRedirectReplayRenderer
extends Object
implements ReplayRenderer

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

Constructor Summary
ArchivalUrlDateRedirectReplayRenderer()
           
 
Method Summary
static String makeFlagDateSpec(String timestamp, WaybackRequest request)
          Given a date, and a WaybackRequest object, create a new datespec + flags which represent the same options as requested by the WaybackRequest
 void renderResource(javax.servlet.http.HttpServletRequest httpRequest, javax.servlet.http.HttpServletResponse httpResponse, WaybackRequest wbRequest, CaptureSearchResult result, Resource resource, ResultURIConverter uriConverter, CaptureSearchResults results)
          return a resource to the user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArchivalUrlDateRedirectReplayRenderer

public ArchivalUrlDateRedirectReplayRenderer()
Method Detail

renderResource

public void renderResource(javax.servlet.http.HttpServletRequest httpRequest,
                           javax.servlet.http.HttpServletResponse httpResponse,
                           WaybackRequest wbRequest,
                           CaptureSearchResult result,
                           Resource resource,
                           ResultURIConverter uriConverter,
                           CaptureSearchResults results)
                    throws javax.servlet.ServletException,
                           IOException
Description copied from interface: ReplayRenderer
return a resource to the user.

Specified by:
renderResource in interface ReplayRenderer
Parameters:
httpRequest - the HttpServletRequest
httpResponse - the HttpServletResponse
wbRequest - the WaybackRequest that returned the results
result - actual CaptureSearchResult that maps to resource to replay
resource - resource to replay
uriConverter - the URI converter to use to translate matching results into replayable URLs
results - all CaptureSearchResults that were returned from the ResourceIndex, probably including other capture dates of the same URL.
Throws:
javax.servlet.ServletException - per usual
IOException - per usual

makeFlagDateSpec

public static String makeFlagDateSpec(String timestamp,
                                      WaybackRequest request)
Given a date, and a WaybackRequest object, create a new datespec + flags which represent the same options as requested by the WaybackRequest

Parameters:
timestamp - the 14-digit timestamp to use
request - the WaybackRequest from which o get extra request option flags
Returns:
a String representing the flags on the WaybackRequest for the specified date


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