planetj.magic
Class AbstractRowRequest

java.lang.Object
  |
  +--planetj.html.AbstractHTMLRenderer
        |
        +--planetj.magic.AbstractMagicRequest
              |
              +--planetj.magic.MagicRequest
                    |
                    +--planetj.magic.AbstractRowRequest
All Implemented Interfaces:
IFeature, IHTMLRenderer, IMagicRequest, IRenderer, Serializable
Direct Known Subclasses:
DeleteRowRequest, InsertRowRequest, UpdateRowRequest

public abstract class AbstractRowRequest
extends MagicRequest

!!DA (8/7/2003 6:28:32 PM) documenation needed

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class planetj.dataengine.IFeature
IFeature.OperationCountFeature
 
Field Summary
 
Fields inherited from class planetj.html.AbstractHTMLRenderer
className
 
Fields inherited from interface planetj.magic.IMagicRequest
IS_COMPLETE, MAGIC_REQUEST, MAGIC_REQUEST_PARAM1, MAGIC_REQUEST_RC, SAME_URI, TYPE, TYPE_PAGE, TYPE_SESSION, TYPE_STATIC, USER_REQUEST_ATTRIBUTES_STORED
 
Fields inherited from interface planetj.html.IHTMLRenderer
HTML
 
Fields inherited from interface planetj.dataengine.IFeature
DEFAULT_MESSAGE_FEATURE, FEATURE_DELETE, FEATURE_INSERT, FEATURE_LEVEL_ENTERPRISE, FEATURE_LEVEL_ENTRY, FEATURE_LEVEL_PROFESSIONAL, FEATURE_LEVEL_STANDARD, FEATURE_UPDATE, MESSAGE_END, MESSAGE_START
 
Constructor Summary
AbstractRowRequest(Row row, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Constructor comment
AbstractRowRequest(String id, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res, String rowId)
          Deprecated. by WK on (11/25/2003 1:39:53 PM) should pass in Row acting request on
 
Method Summary
 IMagicRequest execute(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, DataEngineServlet pServlet)
          execute method comment.
 Row extractDataIntoRow(javax.servlet.http.HttpServletRequest request)
          Gets the Row out of the request and extracts data from the request into it.
abstract  String getDataEngineMode()
          Gets the mode the this magic request should be in when running.
abstract  int getDataEngineRowMode()
          Gets the mode int that this magic request should be in when running.
 boolean getDefaultEndNavigationGroup()
          By default RowRequests end the current navigation group.
abstract  String getDefaultUserMessage()
          Return the default user message after successful execution of this request.
 ExecutingContext getExecutingContext(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Gets the ExecutingContext to use.
 int getFeatureLevel()
          Gets the minimum feature level requried to execute this operation
 Row getRow(javax.servlet.http.HttpServletRequest request)
          Gets the Row out of the request.
 String getRowId()
          Gets the id of the Row in the session.
 void postRowProcess(Row row, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Method called after this RowRequest executes.
 Row prepareRow(Row row, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Prepares this Row to be processed by this RowRequest.
abstract  Row processRow(Row row, ExecutingContext ec, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Subclasses should provide logic in this method to handle necessary processing of the Row.
 void setUserMessage(Row row, int pCount, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Set the message the user will see after execution of this request.
 
Methods inherited from class planetj.magic.MagicRequest
getType, store
 
Methods inherited from class planetj.magic.AbstractMagicRequest
addLinkedRequestAfter, addLinkedRequestBefore, appendUnsupportedHTMLMessage, clone, clone, equals, executeAll, getAnchorName, getBaseField, getBaseRow, getBaseRowCollection, getCurrentURI, getFailMessage, getFirstRequest, getId, getKey, getLastRequest, getMagicServletURI, getMagicURI, getNextURI, getRequestAttribute, getRequestParameter, getRequestParameterValues, getSessionAttribute, getSharedSessionAttribute, getSuccessMessage, hasLinkedRequestsAfter, hasLinkedRequestsBefore, isApplicable, isCompleted, isEndNavigationGroup, isPopup, isReturnToRequester, isSaveResults, isStartNewNavigationGroup, preexecute, removeRequestAttribute, removeSessionAttribute, removeSharedSessionAttribute, setAnchorName, setBaseField, setBaseRow, setBaseRowCollection, setCompleted, setEndNavigationGroup, setFailMessage, setId, setNextURI, setNextURI, setNextURIs, setPopup, setRequestGroupAttribute, setRequestPageAttribute, setRequestPersistentAttribute, setRequestTransientAttribute, setReturnToRequester, setRowEventListener, setSessionAttribute, setSessionSharedAttribute, setStartNewNavigationGroup, setSuccessMessage
 
Methods inherited from class planetj.html.AbstractHTMLRenderer
append, generate, getDisplayType
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface planetj.magic.IMagicRequest
addLinkedRequestAfter, addLinkedRequestBefore, executeAll, getBaseField, getBaseRow, getCurrentURI, getFirstRequest, getId, getKey, getLastRequest, getMagicURI, getNextURI, isCompleted, isEndNavigationGroup, isReturnToRequester, isSaveResults, isStartNewNavigationGroup, setBaseField, setBaseRow, setRowEventListener
 
Methods inherited from interface planetj.html.IHTMLRenderer
append, generate
 
Methods inherited from interface planetj.dataengine.display.IRenderer
getDisplayType
 
Methods inherited from interface planetj.dataengine.IFeature
appendUnsupportedHTMLMessage, isApplicable
 

Constructor Detail

AbstractRowRequest

public AbstractRowRequest(String id,
                          javax.servlet.http.HttpServletRequest req,
                          javax.servlet.http.HttpServletResponse res,
                          String rowId)
Deprecated. by WK on (11/25/2003 1:39:53 PM) should pass in Row acting request on

Constructor comment


AbstractRowRequest

public AbstractRowRequest(Row row,
                          javax.servlet.http.HttpServletRequest request,
                          javax.servlet.http.HttpServletResponse response)
Constructor comment

Method Detail

execute

public final IMagicRequest execute(javax.servlet.http.HttpServletRequest request,
                                   javax.servlet.http.HttpServletResponse response,
                                   DataEngineServlet pServlet)
                            throws CMException
execute method comment.

Specified by:
execute in interface IMagicRequest
Specified by:
execute in class AbstractMagicRequest
Parameters:
request - javax.servlet.http.HttpServletRequest
response - javax.servlet.http.HttpServletResponse
CMException

extractDataIntoRow

public Row extractDataIntoRow(javax.servlet.http.HttpServletRequest request)
                       throws CMException
Gets the Row out of the request and extracts data from the request into it.

Parameters:
request - request from the client
Returns:
Row extracted from the request
CMException

getDataEngineMode

public abstract String getDataEngineMode()
Gets the mode the this magic request should be in when running.

Returns:
mode request should run in

getDataEngineRowMode

public abstract int getDataEngineRowMode()
Gets the mode int that this magic request should be in when running. There are two sets of modes, we should combine these to a single set as soon as time permits. Modes refer to insert, update, and delete requests.

Returns:
mode request should run in
See Also:
Row

getDefaultEndNavigationGroup

public boolean getDefaultEndNavigationGroup()
By default RowRequests end the current navigation group. If Subclasses should not, this method may be overridden.

Overrides:
getDefaultEndNavigationGroup in class AbstractMagicRequest
Returns:
true.

getDefaultUserMessage

public abstract String getDefaultUserMessage()
Return the default user message after successful execution of this request. This method should be overridden by subclasses.

Returns:
String

getExecutingContext

public ExecutingContext getExecutingContext(javax.servlet.http.HttpServletRequest request,
                                            javax.servlet.http.HttpServletResponse response)
                                     throws CMException
Gets the ExecutingContext to use. Subclasses may override to use their own ExecutingContext or to handle any special casing of the ExecutingContext. (e.g. setting attributes on the context)

Parameters:
request - request from the client
Returns:
ExecutingContext to use for request
CMException

getFeatureLevel

public int getFeatureLevel()
Gets the minimum feature level requried to execute this operation

Specified by:
getFeatureLevel in interface IFeature
Overrides:
getFeatureLevel in class AbstractMagicRequest

getRow

public Row getRow(javax.servlet.http.HttpServletRequest request)
Gets the Row out of the request.


getRowId

public String getRowId()
Gets the id of the Row in the session.

Returns:
id of the Row in the session

postRowProcess

public void postRowProcess(Row row,
                           javax.servlet.http.HttpServletRequest request,
                           javax.servlet.http.HttpServletResponse response)
                    throws CMException
Method called after this RowRequest executes. Subclasses may override this method to provide additional functionality after a Row is processed.

Parameters:
row - Row to be processed in some manner
request - request from client
response - response to client
CMException

prepareRow

public Row prepareRow(Row row,
                      javax.servlet.http.HttpServletRequest request,
                      javax.servlet.http.HttpServletResponse response)
               throws CMException
Prepares this Row to be processed by this RowRequest.

Returns:
prepared Row for processing. NOTE: may not be the Row passed in
CMException

processRow

public abstract Row processRow(Row row,
                               ExecutingContext ec,
                               javax.servlet.http.HttpServletRequest request,
                               javax.servlet.http.HttpServletResponse response)
                        throws CMException
Subclasses should provide logic in this method to handle necessary processing of the Row.

Parameters:
row - Row to be processed in some manner
ec - current context in which Row should be process during execution
request - request from client
response - response to client
Returns:
processed Row
CMException

setUserMessage

public void setUserMessage(Row row,
                           int pCount,
                           javax.servlet.http.HttpServletRequest request,
                           javax.servlet.http.HttpServletResponse response)
                    throws CMException
Set the message the user will see after execution of this request.

Parameters:
row - Row to be processed in some manner
request - request from client
response - response to client
CMException