|
© 2002 BEA Systems, Inc. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--com.bea.portal.appflow.processor.AbstractPortalProcessor
|
+--examples.e2e.b2b.processors.AbstractProcessor
|
+--examples.e2e.b2b.processors.QuoteProcessor
The QuoteProcessor
runs business logic for the
price quote portlet (pricequote.portlet).
This class handles the following portlet webflow
events
(See PortalAppflowConstants.PORTLET_WEBFLOW_EVENT_PARAMETER)
directed to the price quote portlet:
Events are acted upon by the process() method of this class.
The "selectQuote" portlet webflow event
indicates that the user has selected a quote from the
price quote portlet. The StateValue
from SessionState must be
StateValue.QPA_SENT or an
IllegalStateException will be thrown.
If a quote was not selected an
will be thrown so the portlet can re-display the quotes to the user.
Otherwise, he InvalidFormDataExceptionexamples.e2e.common.PurchaseQuote for
the selected quote is added to the SessionState
for the user.
On successful complettio the StateValue of the
SessionState is set to
StateValue.CREATE_PO and a value
of Constants.READ_ONLY is returned by
the process() method.
The "bea.portal.framework.internal.refresh" and
"null" events are handled identically. When
encountered the processsor returns an appropriate
response based on the StateValue of the
SessionState.
If the StateValue is
StateValue.START or
StateValue.PRODUCT_SELECTED or
StateValue.PART_SELECTED a value of
Constants.NOT_SELECTED is returned by
process().
If the StateValue is
StateValue.QPA_SENT and the
quote XML file (see BuyerFactory.QUOTE_FILE)
exists, the quotes are parsed, added to the
RequestState and a value of
Constants.DISPLAY is returned by
process().
If the quote XML does not exist and the timeout
(see QpaProcessor.TIMEOUT_PROP) has expired
a value of
Constants.TIMEOUT is returned by
process().
If the quote XML does not exist and the timeout
(see QpaProcessor.TIMEOUT_PROP) has NOT expired
a value of
Constants.NO_DATA is returned by
process().
Otherwise a value of
Constants.READ_ONLY is returned by
process().
| Constructor Summary | |
QuoteProcessor()
Constructs a processor. |
|
| Method Summary | |
java.lang.Object |
process(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
PortalRequest portalRequest,
java.lang.Object requestContext,
PipelineSession session,
RequestState rState,
SessionState sState)
Processes events for the price quote portlet. |
| Methods inherited from class examples.e2e.b2b.processors.AbstractProcessor |
getAppflowEvent,
getInventoryProvider,
getParts,
getPipelineSession,
getPortalEvent,
getPortletEvent,
getProducts,
getPurchaseManager,
getRequestState,
getSessionState,
getTimeoutCalendar,
isPortletMaximized,
process,
submitPO,
submitQPA |
| Methods inherited from class com.bea.portal.appflow.processor.AbstractPortalProcessor |
getCurrentPortletState,
process |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Constructor Detail |
public QuoteProcessor()
| Method Detail |
public java.lang.Object process(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
PortalRequest portalRequest,
java.lang.Object requestContext,
PipelineSession session,
RequestState rState,
SessionState sState)
throws ProcessingException
request - an HttpServletRequest to process.response - the HttpServletRequest associated
with the request.portalRequest - the PortalRequest
associated with this http request.requestContext - the webflow request context.session - the PipelineSession
object associated with this request.requestState - the RequestState associated with this
http request.sessionState - the SessionState associated with this
user session.
if a "selectQuote" event is valid and successfully processed
Constants.READ_ONLY is returned.
The a "bea.portal.framework.internal.refresh" or
"null" event is processed the value returned
is based on the StateValue of the
SessionState.
StateValue is
StateValue.START or
StateValue.PRODUCT_SELECTED or
StateValue.PART_SELECTED a value of
Constants.NOT_SELECTED is returned.
process().
StateValue is
StateValue.QPA_SENT and the
quote XML file (see BuyerFactory.QUOTE_FILE)
exists a value of
Constants.DISPLAY is returned.
StateValue is
StateValue.QPA_SENT, the
quote XML file (see BuyerFactory.QUOTE_FILE)
does NOT exist and the quote timeout has expired
Constants.TIMEOUT is returned.
StateValue is
StateValue.QPA_SENT, the
quote XML file (see BuyerFactory.QUOTE_FILE)
does not exist and the quote timeout has NOT expired
Constants.NO_DATA is returned.
Constants.READ_ONLY is returned.
StateValue is NOT
StateValue.QPA_SENT.
HttpServletRequest is not valid.
|
© 2002 BEA Systems, Inc. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||