com.sri.emo.controller
Class PartAction

java.lang.Object
  extended by org.apache.struts.action.Action
      extended by com.jcorporate.expresso.core.controller.Controller
          extended by com.jcorporate.expresso.core.controller.DBController
              extended by com.sri.common.controller.AbstractDBController
                  extended by com.sri.emo.controller.PartAction
All Implemented Interfaces:
Serializable

public class PartAction
extends AbstractDBController

manipulate the parts of an entity--the metadata handler

Author:
larry hamel
See Also:
Serialized Form

Field Summary
static String ATTRIB
           
static String ATTRIB_SET_BLOCK
           
static String CONFIRM_DELETE_RELATION
           
static String CONTROLLER_NAME
           
static String DO_ADD_ENTITY
           
static String DO_ADD_PART
           
static String DO_ADD_RELATION
           
static String DO_DEC_PART_NUM
           
static String DO_DELETE_ENTITY
           
static String DO_DELETE_PART
           
static String DO_DELETE_RELATION
           
static String DO_EDIT_ENTITY
           
static String DO_EDIT_PART
           
static String DO_EDIT_RELATION
           
static String DO_IMPORT_ENTITY
           
static String DO_INC_PART_NUM
           
static String ENTITY
           
static String GENERATE_ALL_ENTITY_DOCBOOK
           
static String GENERATE_DOCS
           
static String GENERATE_ENTITY_XML_DOCS
           
static String GENERATE_GUIDE_DOCS
           
static String IS_OWNED
           
static String LIST_ENTITIES
           
static String LIST_RELATIONS
           
static String MODEL_EDIT_GROUP_DEFAULT_SETUP_CODE
           
static String PART
           
static String PROMPT_ADD_ENTITY
           
static String PROMPT_ADD_PART
           
static String PROMPT_ADD_PART_OWNED
           
static String PROMPT_ADD_PART_SHARED
           
static String PROMPT_ADD_RELATION
           
static String PROMPT_DELETE_ENTITY
           
static String PROMPT_DELETE_PART
           
static String PROMPT_EDIT_ENTITY
           
static String PROMPT_EDIT_PART
           
static String PROMPT_EDIT_RELATION
           
static String PROMPT_IMPORT_ENTITY
           
static String READ_GROUP
           
static String READ_GROUP_DEFAULT_SETUP_CODE
           
static String RELATED_ENTITY_TYPE
           
static String WRITE_GROUP
           
static String WRITE_GROUP_DEFAULT_SETUP_CODE
           
 
Fields inherited from class com.sri.common.controller.AbstractDBController
COLUMN, COMMON_FOOTER_HANDLER, COMMON_HEADER_HANDLER, DELIMIT, EDIT_GROUP_DISPLAY, EMBEDDED_MODE, FOOTER, MAX_CHARS_OUTPUT, MAX_TEXTAREA_LENGTH, MULTIPLE_TEXTAREA_NUM_LINES, REQUEST_CONTAINER, ROW, ROW_BLOCK, SESSION_CONTAINER, SINGLE_TEXTAREA_NUM_LINES, TEXTAREA_NUM_COLS, WARNING_LIST
 
Fields inherited from class com.jcorporate.expresso.core.controller.DBController
CACHE_NAME
 
Fields inherited from class com.jcorporate.expresso.core.controller.Controller
CONTROLLER_PARAM_KEY, CTL_SUCC_CTL, CTL_SUCC_STATE, CTL_SUCC_TRAN, mLog, NEWSTATE_EXCEPTION_KEY, ORIGINAL_URL_KEY, REQUEST_KEY, RESPONSE_KEY, RETURN_TO_SENDER_TRAN, STATE_ERR_CTL, STATE_ERR_STATE, STATE_ERR_TRAN, STATE_PARAM_KEY, STATE_SUCC_CTL, STATE_SUCC_STATE, STATE_SUCC_TRAN
 
Fields inherited from class org.apache.struts.action.Action
defaultLocale, servlet
 
Constructor Summary
PartAction()
           
 
Method Summary
 String getTitle()
          Returns the title of this controller
static org.dom4j.Element parseXML(Reader reader)
          Parses the XML into Elements.
protected  void runConfirmDeleteEntityState(ExpressoRequest request, ExpressoResponse response)
          Prompt to confirm delete entity.
protected  void runConfirmDeletePartState(ExpressoRequest request, ExpressoResponse response)
          Prompt to confirm deletion an Part.
protected  void runConfirmDeleteRelationState(ExpressoRequest request, ExpressoResponse response)
          Confirm deletion of a relation.
protected  void runDoAddEntityState(ExpressoRequest request, ExpressoResponse response)
          Prompt to add an Entity.
protected  void runDoAddPartState(ExpressoRequest request, ExpressoResponse response)
          Do the addition for part.
protected  void runDoAddRelationState(ExpressoRequest request, ExpressoResponse response)
          Do the addition for part.
protected  void runDoDecPartNumState(ExpressoRequest request, ExpressoResponse response)
          Decrement Part number.
protected  void runDoDeleteEntityState(ExpressoRequest request, ExpressoResponse response)
          Prompt to confirm delete entity.
protected  void runDoDeletePartState(ExpressoRequest request, ExpressoResponse response)
          Do the deletion of part.
protected  void runDoDeleteRelationState(ExpressoRequest request, ExpressoResponse response)
          Do the addition for relation.
protected  void runDoEditEntityState(ExpressoRequest request, ExpressoResponse response)
          Do the edits.
protected  void runDoEditPartState(ExpressoRequest request, ExpressoResponse response)
          Do the edits for parts.
protected  void runDoEditRelationState(ExpressoRequest request, ExpressoResponse response)
          Do the addition for relation.
protected  void runDoImportEntityState(ExpressoRequest request, ExpressoResponse response)
          Import XML for a given object type; update existing if found.
protected  void runDoIncPartNumState(ExpressoRequest request, ExpressoResponse response)
          Increment Part number.
protected  void runGenerateAllEntityDocbookState(ExpressoRequest request, ExpressoResponse response)
          Generate XML format documentation for a given object.
protected  void runGenerateDocsState(ExpressoRequest request, ExpressoResponse response)
          Generate html doc for all entities, with their parts.
protected  void runGenerateEntityXMLDocsState(ExpressoRequest request, ExpressoResponse response)
          Generate XML format documentation for a given object.
protected  void runGenGuideDocsState(ExpressoRequest request, ExpressoResponse response)
          Generate html doc for all entities, with their parts.
protected  void runListEntitiesState(ExpressoRequest request, ExpressoResponse response)
           
protected  void runListRelationsState(ExpressoRequest request, ExpressoResponse response)
          Do the addition for part.
protected  void runPromptAddEntityState(ExpressoRequest request, ExpressoResponse response)
          Prompt to add an Entity.
protected  void runPromptAddPartState(ExpressoRequest request, ExpressoResponse response)
          Prompt to add an Part.
protected  void runPromptAddRelationState(ExpressoRequest request, ExpressoResponse response)
          Prompt to add an relation.
protected  void runPromptEditEntityState(ExpressoRequest request, ExpressoResponse response)
          Prompt for one entity.
protected  void runPromptEditPartState(ExpressoRequest request, ExpressoResponse response)
          Prompt for edits.
protected  void runPromptEditRelationState(ExpressoRequest request, ExpressoResponse response)
          Prompt to edit a relation.
protected  void runPromptImportEntityState(ExpressoRequest request, ExpressoResponse response)
          Import XML for a given object type; update existing if found.
 
Methods inherited from class com.sri.common.controller.AbstractDBController
addEmbeddedParameter, addWarning, addWarningList, getActionForwarding, getCheckbox, getPermsTrans, getPrettyXML, getTextArea, getTextArea, getWarningList, isEmbeddedMode, isValidAndPopulated, outputXML, populateDBObject, postPerform, prePerform, stateAllowed, str, strTrunc, trimAllTextFields
 
Methods inherited from class com.jcorporate.expresso.core.controller.DBController
getString, isAllowed
 
Methods inherited from class com.jcorporate.expresso.core.controller.Controller
addFinalState, addPromptTransitions, addRegDomainParamtoSession, addRequestedURLtoSession, addState, addStatePairing, endTimer, execute, findControllerForm, generateToken, getActionForward, getControllerChainingTransition, getControllerSecurityTransition, getFinalState, getInitialState, getLogger, getParamValues, getRequestURL, getSchema, getSchemaHierarchy, getSchemaInstance, getSchemaStack, getState, getStates, getString, getString, handleException, instantiate, isFinalState, isHandleState, isPromptState, isTokenValid, loadStateForm, newExpressoState, newState, nextHandleState, nextPromptState, populateStateForm, postPerform, prePerform, previousPromptState, processRequestTransitions, processTransitions, redirectRequest, redirectRequest, remapFromExtension, resetToken, saveToken, setControllerChainingTransition, setControllerSecurityTransition, setCurrentState, setInitialState, setSchema, setSchema, setupDefaultValues, setupReturnToSender, setupSubclassLog, transition, transition, transition, unloadStateForm
 
Methods inherited from class org.apache.struts.action.Action
addErrors, addMessages, execute, generateToken, getDataSource, getDataSource, getErrors, getLocale, getMessages, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, resetToken, saveErrors, saveErrors, saveMessages, saveMessages, saveToken, setLocale, setServlet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTROLLER_NAME

public static String CONTROLLER_NAME

LIST_ENTITIES

public static final String LIST_ENTITIES
See Also:
Constant Field Values

PROMPT_ADD_PART

public static final String PROMPT_ADD_PART
See Also:
Constant Field Values

DO_ADD_PART

public static final String DO_ADD_PART
See Also:
Constant Field Values

PROMPT_ADD_ENTITY

public static final String PROMPT_ADD_ENTITY
See Also:
Constant Field Values

DO_ADD_ENTITY

public static final String DO_ADD_ENTITY
See Also:
Constant Field Values

PROMPT_EDIT_PART

public static final String PROMPT_EDIT_PART
See Also:
Constant Field Values

DO_EDIT_PART

public static final String DO_EDIT_PART
See Also:
Constant Field Values

PROMPT_EDIT_RELATION

public static final String PROMPT_EDIT_RELATION
See Also:
Constant Field Values

DO_EDIT_RELATION

public static final String DO_EDIT_RELATION
See Also:
Constant Field Values

PROMPT_ADD_RELATION

public static final String PROMPT_ADD_RELATION
See Also:
Constant Field Values

DO_ADD_RELATION

public static final String DO_ADD_RELATION
See Also:
Constant Field Values

CONFIRM_DELETE_RELATION

public static final String CONFIRM_DELETE_RELATION
See Also:
Constant Field Values

DO_DELETE_RELATION

public static final String DO_DELETE_RELATION
See Also:
Constant Field Values

LIST_RELATIONS

public static final String LIST_RELATIONS
See Also:
Constant Field Values

PROMPT_EDIT_ENTITY

public static final String PROMPT_EDIT_ENTITY
See Also:
Constant Field Values

DO_EDIT_ENTITY

public static final String DO_EDIT_ENTITY
See Also:
Constant Field Values

GENERATE_ENTITY_XML_DOCS

public static final String GENERATE_ENTITY_XML_DOCS
See Also:
Constant Field Values

DO_IMPORT_ENTITY

public static final String DO_IMPORT_ENTITY
See Also:
Constant Field Values

PROMPT_IMPORT_ENTITY

public static final String PROMPT_IMPORT_ENTITY
See Also:
Constant Field Values

PROMPT_DELETE_ENTITY

public static final String PROMPT_DELETE_ENTITY
See Also:
Constant Field Values

DO_DELETE_ENTITY

public static final String DO_DELETE_ENTITY
See Also:
Constant Field Values

PROMPT_DELETE_PART

public static final String PROMPT_DELETE_PART
See Also:
Constant Field Values

DO_DELETE_PART

public static final String DO_DELETE_PART
See Also:
Constant Field Values

DO_INC_PART_NUM

public static final String DO_INC_PART_NUM
See Also:
Constant Field Values

DO_DEC_PART_NUM

public static final String DO_DEC_PART_NUM
See Also:
Constant Field Values

GENERATE_DOCS

public static final String GENERATE_DOCS
See Also:
Constant Field Values

GENERATE_GUIDE_DOCS

public static final String GENERATE_GUIDE_DOCS
See Also:
Constant Field Values

GENERATE_ALL_ENTITY_DOCBOOK

public static final String GENERATE_ALL_ENTITY_DOCBOOK
See Also:
Constant Field Values

ATTRIB_SET_BLOCK

public static final String ATTRIB_SET_BLOCK
See Also:
Constant Field Values

IS_OWNED

public static final String IS_OWNED
See Also:
Constant Field Values

ATTRIB

public static final String ATTRIB
See Also:
Constant Field Values

RELATED_ENTITY_TYPE

public static final String RELATED_ENTITY_TYPE
See Also:
Constant Field Values

PROMPT_ADD_PART_OWNED

public static final String PROMPT_ADD_PART_OWNED
See Also:
Constant Field Values

PROMPT_ADD_PART_SHARED

public static final String PROMPT_ADD_PART_SHARED
See Also:
Constant Field Values

ENTITY

public static final String ENTITY
See Also:
Constant Field Values

PART

public static final String PART
See Also:
Constant Field Values

WRITE_GROUP

public static final String WRITE_GROUP
See Also:
Constant Field Values

READ_GROUP

public static final String READ_GROUP
See Also:
Constant Field Values

READ_GROUP_DEFAULT_SETUP_CODE

public static final String READ_GROUP_DEFAULT_SETUP_CODE
See Also:
Constant Field Values

WRITE_GROUP_DEFAULT_SETUP_CODE

public static final String WRITE_GROUP_DEFAULT_SETUP_CODE
See Also:
Constant Field Values

MODEL_EDIT_GROUP_DEFAULT_SETUP_CODE

public static final String MODEL_EDIT_GROUP_DEFAULT_SETUP_CODE
See Also:
Constant Field Values
Constructor Detail

PartAction

public PartAction()
Method Detail

getTitle

public String getTitle()
Returns the title of this controller

Overrides:
getTitle in class Controller
Returns:
String: The Controller Name.

runListEntitiesState

protected void runListEntitiesState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Throws:
ControllerException

runPromptEditEntityState

protected void runPromptEditEntityState(ExpressoRequest request,
                                        ExpressoResponse response)
                                 throws ControllerException,
                                        DBException
Prompt for one entity.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.
DBException - upon database error.

runDoEditEntityState

protected void runDoEditEntityState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Do the edits.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runPromptEditPartState

protected void runPromptEditPartState(ExpressoRequest request,
                                      ExpressoResponse response)
                               throws ControllerException
Prompt for edits.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoEditPartState

protected void runDoEditPartState(ExpressoRequest request,
                                  ExpressoResponse response)
                           throws ControllerException
Do the edits for parts.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runGenerateDocsState

protected void runGenerateDocsState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Generate html doc for all entities, with their parts.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runGenGuideDocsState

protected void runGenGuideDocsState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Generate html doc for all entities, with their parts.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.
To Do:
remove

runGenerateEntityXMLDocsState

protected void runGenerateEntityXMLDocsState(ExpressoRequest request,
                                             ExpressoResponse response)
                                      throws ControllerException
Generate XML format documentation for a given object.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoImportEntityState

protected void runDoImportEntityState(ExpressoRequest request,
                                      ExpressoResponse response)
                               throws ControllerException
Import XML for a given object type; update existing if found.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runPromptImportEntityState

protected void runPromptImportEntityState(ExpressoRequest request,
                                          ExpressoResponse response)
                                   throws ControllerException
Import XML for a given object type; update existing if found.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runGenerateAllEntityDocbookState

protected void runGenerateAllEntityDocbookState(ExpressoRequest request,
                                                ExpressoResponse response)
                                         throws ControllerException
Generate XML format documentation for a given object.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runPromptAddEntityState

protected void runPromptAddEntityState(ExpressoRequest request,
                                       ExpressoResponse response)
                                throws ControllerException
Prompt to add an Entity.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoAddEntityState

protected void runDoAddEntityState(ExpressoRequest request,
                                   ExpressoResponse response)
                            throws ControllerException
Prompt to add an Entity.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runPromptAddPartState

protected void runPromptAddPartState(ExpressoRequest request,
                                     ExpressoResponse response)
                              throws ControllerException
Prompt to add an Part.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoAddPartState

protected void runDoAddPartState(ExpressoRequest request,
                                 ExpressoResponse response)
                          throws ControllerException
Do the addition for part.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoDeletePartState

protected void runDoDeletePartState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Do the deletion of part.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runConfirmDeletePartState

protected void runConfirmDeletePartState(ExpressoRequest request,
                                         ExpressoResponse response)
                                  throws ControllerException
Prompt to confirm deletion an Part.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoIncPartNumState

protected void runDoIncPartNumState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Increment Part number.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoDecPartNumState

protected void runDoDecPartNumState(ExpressoRequest request,
                                    ExpressoResponse response)
                             throws ControllerException
Decrement Part number.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runConfirmDeleteEntityState

protected void runConfirmDeleteEntityState(ExpressoRequest request,
                                           ExpressoResponse response)
                                    throws ControllerException
Prompt to confirm delete entity.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoDeleteEntityState

protected void runDoDeleteEntityState(ExpressoRequest request,
                                      ExpressoResponse response)
                               throws ControllerException
Prompt to confirm delete entity.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runPromptAddRelationState

protected void runPromptAddRelationState(ExpressoRequest request,
                                         ExpressoResponse response)
                                  throws ControllerException
Prompt to add an relation.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoAddRelationState

protected void runDoAddRelationState(ExpressoRequest request,
                                     ExpressoResponse response)
                              throws ControllerException,
                                     NonHandleableException
Do the addition for part.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.
NonHandleableException - upon fatal error.

runPromptEditRelationState

protected void runPromptEditRelationState(ExpressoRequest request,
                                          ExpressoResponse response)
                                   throws ControllerException
Prompt to edit a relation.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoEditRelationState

protected void runDoEditRelationState(ExpressoRequest request,
                                      ExpressoResponse response)
                               throws ControllerException,
                                      NonHandleableException
Do the addition for relation.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.
NonHandleableException - upon fatal error.

runListRelationsState

protected void runListRelationsState(ExpressoRequest request,
                                     ExpressoResponse response)
                              throws ControllerException,
                                     NonHandleableException
Do the addition for part.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.
NonHandleableException - upon fatal error.

runConfirmDeleteRelationState

protected void runConfirmDeleteRelationState(ExpressoRequest request,
                                             ExpressoResponse response)
                                      throws ControllerException
Confirm deletion of a relation.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.

runDoDeleteRelationState

protected void runDoDeleteRelationState(ExpressoRequest request,
                                        ExpressoResponse response)
                                 throws ControllerException,
                                        NonHandleableException
Do the addition for relation.

Parameters:
request - The ExpressoRequest Object: our parameters.
response - The ExpressoResponse object: what we populate.
Throws:
ControllerException - upon error.
NonHandleableException - upon fatal error.

parseXML

public static org.dom4j.Element parseXML(Reader reader)
                                  throws Exception
Parses the XML into Elements.

Parameters:
reader - Reader the Xml Reader instance.
Returns:
Element: Constructed XML
Throws:
Exception - upon error.


Copyright © 2004-2006 Codeguild, Inc.. All Rights Reserved.