com.ibm.portal.resolver.helper
Class CORLookupService
java.lang.Object
com.ibm.portal.resolver.helper.CORLookupService
- All Implemented Interfaces:
- CORService, LookupService
-
public class CORLookupService
- extends java.lang.Object
- implements LookupService, CORService
Lookup service that implements itself by dispatching to a lookup service
provided by the COR.
Constructor Summary
|
CORLookupService()
initialize the lookup service without default lookup |
CORLookupService(LookupService aDefaultService)
Initialize the lookup service passing a default service reference that
will be used if no COR service can be found |
Method Summary
|
protected LookupService |
lookupService(java.net.URI uri,
java.lang.Class<LookupService> cls,
Context ctx)
Uses the COR to find a service that exposes a particular interface. |
Lookup |
newLookup(java.net.URI uri,
java.lang.String verb,
java.util.Map<java.lang.String,java.lang.String[]> params,
boolean bIsProtected,
boolean bIsSecure,
Context ctx)
Constructs an XML source that produces an ATOM entry that describes the
access points for the URI. |
Methods inherited from class java.lang.Object
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
defaultService
protected final LookupService defaultService
- default lookup service
SINGLETON
public static final LookupService SINGLETON
- Singleton that can be used to do COR lookups that don't require a
fallback
CORLookupService
public CORLookupService()
- initialize the lookup service without default lookup
CORLookupService
public CORLookupService(LookupService aDefaultService)
- Initialize the lookup service passing a default service reference that
will be used if no COR service can be found
- Parameters:
- aDefaultService - default lookup service, may be null
lookupService
protected LookupService lookupService(java.net.URI uri,
java.lang.Class<LookupService> cls,
Context ctx)
throws org.eclipse.core.runtime.CoreException,
ServiceNotFoundException
- Uses the COR to find a service that exposes a particular interface. The
fully specified classname of the interface is interpreted as the ID of
the service
- Parameters:
- uri -
- cls -
- ctx -
- Returns:
-
- Throws:
- org.eclipse.core.runtime.CoreException - - some COR stuff failed
- ServiceNotFoundException - - the service could not be located
newLookup
public Lookup newLookup(java.net.URI uri,
java.lang.String verb,
java.util.Map<java.lang.String,java.lang.String[]> params,
boolean bIsProtected,
boolean bIsSecure,
Context ctx)
throws javax.xml.transform.TransformerException,
java.io.IOException
- Description copied from interface: LookupService
- Constructs an XML source that produces an ATOM entry that describes the
access points for the URI. The method may return null in
case there is no customized lookup for the URI / params combination. In
this case a client is free to select a default lookup. If this is not the
intended behaviour, the service can either return a dummy lookup object
that returns an empty source or throw an exception.
- Specified by:
- newLookup in interface LookupService
- Parameters:
- uri - POC URI
- verb - lookup verb
- params - parameter map
- bIsProtected - true, if the lookup should refer to the protected context
- bIsSecure - true, if the lookup should refer to the secure context
- ctx - COR context
- Returns:
- lookup object that can produce an ATOM feed that describes the
entry point and meta information for a service that can handle
the URI. Implementors may return null to indicate
that the service does not handle the lookup for the specified
input parameters.
- Throws:
- javax.xml.transform.TransformerException - -
if the lookup cannot be created
- java.io.IOException - -
if an IO error occurred when trying to do the lookup