com.ibm.commerce.adapter
Interface HttpAdapter

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

public interface HttpAdapter
extends DeviceFormatAdapter

HttpAdapter defines the device format interface that is required for all adapters that handles HttpServletRequests.


Field Summary
static java.lang.String COPYRIGHT
           
static java.lang.Integer DEVFMTID_BROWSER
           
static java.lang.String DEVFMTNAME_BROWSER
           
static java.lang.String DEVFMTNAME_IMODE
           
static java.lang.String DEVFMTTYP_BROWSER
           
static java.lang.String DEVFMTTYP_PVCDEVICE
           
static java.lang.String DEVFMTTYP_XMLFMT
           
static java.lang.Integer DEVFMTTYPID_BROWSER
           
static java.lang.Integer DEVFMTTYPID_PVC
           
static java.lang.Integer DEVFMTTYPID_XML
           
 
Method Summary
 HttpAdapterDesc getAdapterDesc()
          Return the descripter that describes this Http adapter.
 com.ibm.commerce.adapter.HttpServletRequest getRequest()
          Gets the Http request object.
 java.lang.String getRequestName()
          Gets the request name .
 TypedProperty getRequestProperties()
          Gets the request properties assoiciated with this request.
 com.ibm.commerce.adapter.HttpServletResponse getResponse()
          Gets the Http Servlet Response object.
 boolean httpsRedirection()
          Returns true if Https redirection is required.
 com.ibm.commerce.adapter.HttpControllerRequestObject preprocessRequest()
          This method preprocess a HttpServletRequest and return a HttpControllerRequestObject.
 void processRequest(com.ibm.commerce.adapter.ServletContext servletContext, java.lang.String encoding, boolean storeCommand)
          This method is responsible for invoking the web controller to process the incoming request.
 void setAdapterDesc(HttpAdapterDesc val)
          Sets the HttpAdapterDesc value.
 void setRequest(com.ibm.commerce.adapter.HttpServletRequest req)
          Sets the HttpServletRequest object.
 void setRequestProperties(TypedProperty val)
          Sets the request properties assoiciated with this request.
 void setResponse(com.ibm.commerce.adapter.HttpServletResponse resp)
          Sets the HttpServletResponse object.
 
Methods inherited from interface com.ibm.commerce.adapter.DeviceFormatAdapter
getDefaultDeviceFormatId, getDeviceFormatId, getDeviceFormatName, getDeviceFormatType, getDeviceFormatTypeId, getDocumentPathName, getSessionContext, postInvokeCommand, preInvokeCommand, processErrorResponse, processResponse, setDefaultDeviceFormatId, setDeviceFormatId, setDeviceFormatName, setDeviceFormatType, setDeviceFormatTypeId
 

Field Detail

COPYRIGHT

public static final java.lang.String COPYRIGHT

DEVFMTID_BROWSER

public static final java.lang.Integer DEVFMTID_BROWSER

DEVFMTNAME_BROWSER

public static final java.lang.String DEVFMTNAME_BROWSER

DEVFMTNAME_IMODE

public static final java.lang.String DEVFMTNAME_IMODE

DEVFMTTYP_BROWSER

public static final java.lang.String DEVFMTTYP_BROWSER

DEVFMTTYP_PVCDEVICE

public static final java.lang.String DEVFMTTYP_PVCDEVICE

DEVFMTTYP_XMLFMT

public static final java.lang.String DEVFMTTYP_XMLFMT

DEVFMTTYPID_BROWSER

public static final java.lang.Integer DEVFMTTYPID_BROWSER

DEVFMTTYPID_PVC

public static final java.lang.Integer DEVFMTTYPID_PVC

DEVFMTTYPID_XML

public static final java.lang.Integer DEVFMTTYPID_XML
Method Detail

getAdapterDesc

public HttpAdapterDesc getAdapterDesc()
Return the descripter that describes this Http adapter.

getRequest

public com.ibm.commerce.adapter.HttpServletRequest getRequest()
Gets the Http request object.

getRequestName

public java.lang.String getRequestName()
Gets the request name .

getRequestProperties

public TypedProperty getRequestProperties()
Gets the request properties assoiciated with this request.

Specified by:
getRequestProperties in interface DeviceFormatAdapter
Returns:
TypedProperty - request properties

getResponse

public com.ibm.commerce.adapter.HttpServletResponse getResponse()
Gets the Http Servlet Response object.

httpsRedirection

public boolean httpsRedirection()
Returns true if Https redirection is required. That is, if a requests comes in as Http but the command requires https, the request will be redirected to https.

preprocessRequest

public com.ibm.commerce.adapter.HttpControllerRequestObject preprocessRequest()
This method preprocess a HttpServletRequest and return a HttpControllerRequestObject.

processRequest

public void processRequest(com.ibm.commerce.adapter.ServletContext servletContext,
                           java.lang.String encoding,
                           boolean storeCommand)
                    throws ECException
This method is responsible for invoking the web controller to process the incoming request. It will invoke processErrorView() if it detected an error in the preprocessing of the request. It will invoke processView() to handle a view such as relogin It will invoke processRequest() to handle a requler request which can be a controller command, a view command, or just a jsp page.

Parameters:
servletContext - ServletContext - the servlet context associated with this request
encoding - String - the encoding used for the incoming parameters
storeCommand - boolean - true if this is a store command

setAdapterDesc

public void setAdapterDesc(HttpAdapterDesc val)
Sets the HttpAdapterDesc value.

setRequest

public void setRequest(com.ibm.commerce.adapter.HttpServletRequest req)
Sets the HttpServletRequest object.

setRequestProperties

public void setRequestProperties(TypedProperty val)
Sets the request properties assoiciated with this request.

setResponse

public void setResponse(com.ibm.commerce.adapter.HttpServletResponse resp)
Sets the HttpServletResponse object.