edu.ucsb.adl.middleware
Interface UnloadServiceGatekeeper

All Known Implementing Classes:
BasicPasswordGatekeeper, CombinationGatekeeper, ConstantGatekeeper, IPAddressGatekeeper

public interface UnloadServiceGatekeeper

The interface between the ADL unload service and the gatekeeper that controls access to the service. The ADL unload service creates the gatekeeper by dynamically loading the gatekeeper class and calling the following class method:

public static UnloadServiceGatekeeper createGatekeeper (
    ExtendedProperties propertyList, String argument)
Gatekeeper startup parameters can be obtained from propertyList. argument is an additional, gatekeeper-specific startup parameter.

Version:
$Header: /export/home/gjanee/middleware/edu/ucsb/adl/middleware/RCS/UnloadServiceGatekeeper.java,v 1.2 2004/09/21 18:22:27 gjanee Exp $

$Log: UnloadServiceGatekeeper.java,v $ Revision 1.2 2004/09/21 18:22:27 gjanee
Minor documentation change.

Revision 1.1 2001/08/31 22:39:14 gjanee
Initial revision

Author:
Greg Janée
Alexandria Digital Library

Method Summary
 void destroy()
          Frees any resources held by the gatekeeper.
 boolean unloadServiceAllowed(javax.servlet.ServletRequest request, java.lang.String collection)
          Returns true if the request is authorized, that is, if the client is allowed to unload the specified collection from the middleware.
 

Method Detail

unloadServiceAllowed

public boolean unloadServiceAllowed(javax.servlet.ServletRequest request,
                                    java.lang.String collection)
                             throws MiddlewareException
Returns true if the request is authorized, that is, if the client is allowed to unload the specified collection from the middleware. This method must be multithread-safe.

Parameters:
request - The full request.
collection - The collection name, e.g., "adl_catalog".
Returns:
true if the request is authorized.
Throws:
BadRequestException - If request is not valid.
InternalErrorException - If the authorization cannot otherwise be determined.
MiddlewareException
See Also:
UnloadService

destroy

public void destroy()
Frees any resources held by the gatekeeper.