com.ibm.commerce.adapter
Interface HttpAdapterFactory

All Superinterfaces:
DeviceFormatAdapter
All Known Implementing Classes:
AbstractHttpAdapter, HttpProgramAdapterImpl

public interface HttpAdapterFactory
extends DeviceFormatAdapter

Reserved for IBM internal use. HttpAdapterFactory defines the interface that is required for a http adapter factory. The adapter factory is called to check whether a request can be handled by the associated adapter and also to instantiate an adapter.


Field Summary
static java.lang.String COPYRIGHT
          IBM Copyright notice field.
 
Method Summary
 boolean checkDeviceFormat(javax.servlet.http.HttpServletRequest req, TypedProperty prop)
          Reserved for IBM internal use.
  HttpAdapter createAdapter(HttpServletRequest request, HttpServletResponse response, TypedProperty param)
          Reserved for IBM internal use.
  HttpAdapterDesc getAdapterDesc()
          Reserved for IBM internal use.
 void initFactory(org.w3c.dom.Element node)
          Reserved for IBM internal use.
 boolean isEnabled()
          Reserved for IBM internal use.
 
Methods inherited from interface com.ibm.commerce.adapter. DeviceFormatAdapter
getDefaultDeviceFormatId, getDeviceFormatId, getDeviceFormatName, getDeviceFormatType, getDeviceFormatTypeId, getDocumentPathName, getRequestProperties, getSessionContext, postInvokeCommand, preInvokeCommand, processErrorResponse, processResponse, setDefaultDeviceFormatId, setDeviceFormatId, setDeviceFormatName, setDeviceFormatType, setDeviceFormatTypeId
 

Field Detail
public static final java.lang.String COPYRIGHT
IBM Copyright notice field.
See Also:
Constant Field Values
Method Detail

checkDeviceFormat

public boolean checkDeviceFormat(javax.servlet.http.HttpServletRequest req,
TypedProperty prop)
Reserved for IBM internal use. Return true if the input request can be processed by this adapter.
Returns:
Either true if this request can be processed by this adapter or false if this request cannot be processed by this adapter.

getAdapterDesc

public HttpAdapterDesc getAdapterDesc()
Reserved for IBM internal use. Returns the adapter descriptor.
Returns:
The descriptor for this adapter

initFactory

public void initFactory(org.w3c.dom.Element node)
                 throws java.lang.Exception
Reserved for IBM internal use. Initialize the Adapter factory based on the informtion defined in the DOM node.
Parameters:
node - the configuration for the adapter.
Throws:
java.lang.Exception - if there was a problem initializing the adapter.

isEnabled

public boolean isEnabled()
Reserved for IBM internal use. Returns true if adapter is enabled.
Returns:
Whether the adapter is enabled.

createAdapter

public HttpAdapter createAdapter(HttpServletRequest request,
                                 HttpServletResponse response,
TypedProperty param)
Reserved for IBM internal use. This method returns an instance of this adapter if the request has the format defined by this adapter. This method should first call the checkDeviceFormat() method. If it returns true, then it will instantiate an instance of this adapter. The adapter instance returned will be initialized with request, response and request properties initialized.
Parameters:
request - the HTTP request object.
response - the HTTP response object.
param - the request properties.
Returns:
An object that is an instance of HttpAdapter that can handle the request or null.