atg.epub.servlet
Class ProjectFormHandler

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.epub.servlet.PortletFormHandler
              extended by atg.epub.servlet.PublishingPortletFormHandler
                  extended by atg.epub.servlet.ProjectFormHandler
All Implemented Interfaces:
atg.droplet.ObjectFormHandler, atg.naming.AbsoluteNameable, NameContextBindingListener, NameContextElement, atg.naming.NameContextParentable, NameResolver, AdminableService, atg.nucleus.Configured, ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, VariableArgumentApplicationLogging, ComponentNameResolver, Service, ServiceListener, java.util.EventListener

public class ProjectFormHandler
extends PublishingPortletFormHandler

Form Handler for adding or deleting an asset to/from a project.


Field Summary
static int ADD_ASSET_ACTION
           
static int CANCEL_BACKGROUND_TASK
           
static java.lang.String CLASS_VERSION
          Class version string
static int DEL_ASSET_ACTION
           
static int DISCARD_ASSET_ACTION
           
static int MOVE_ASSET_ACTION
           
static int RESOLVE_NON_CONFLICTING
           
static int REVERT_ASSET_ACTION
           
static int sResolveNonConflictingTaskType
           
 
Fields inherited from class atg.epub.servlet.PublishingPortletFormHandler
mProcess, mProject, sConfiguration, sProcessHome, sProcessTaskInfoHome, sProjectHome
 
Fields inherited from class atg.epub.servlet.PortletFormHandler
mFormExceptions, PARAM_USE_FORWARDS, sTransactionManager
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
ProjectFormHandler()
           
 
Method Summary
 void clearAssetPlaceholder(java.lang.String[] assets)
          Clears any placeholder values that were held by assets being discarded
 int getADD_ASSET_ACTION()
           
 java.lang.String getAsset()
           
 int getAssetAction()
          Used by handlePerformAssetAction handler to decide which of handleAddAssets or handleDiscardAssets methods to invoke
 java.lang.String[] getAssets()
           
 int getCANCEL_BACKGROUND_TASK()
           
 java.lang.String getConfirmationMessage()
           
 int getDEL_ASSET_ACTION()
           
 int getDISCARD_ASSET_ACTION()
           
 int getMOVE_ASSET_ACTION()
           
 java.lang.String getMoveAssetsProjectId()
           
 java.lang.String getPipeDelimitedAssetURIList()
           
 java.lang.String getPlaceholderName()
           
protected  java.util.Set getReferenceWorkingVersions(RepositoryItem pItem, Workspace pWorkspace)
          Given a RepositoryItem, return a list of reference repository in the Workspace.
 int getRESOLVE_NON_CONFLICTING()
           
 int getREVERT_ASSET_ACTION()
           
 java.lang.String getSuccessMessage()
          Returns indicates a successful operation
static java.lang.String getTaskName(java.lang.String pID, int pTaskType)
           
 int getTaskType()
           
 java.lang.String getVersion()
           
 void handleAddAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle method to add an asset to a project.
 void handleAddAssets(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle method to add an asset to a project.
 void handleCancelBackgroundTask(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle method to revert an asset to a given version
 void handleCancelBackgroundTask(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle method to revert an asset
 void handleDiscardAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle method to add a note to a project.
 void handleDiscardAssets(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle method to add a note to a project.
 void handleMoveAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle method to move assets to another project
 void handleMoveAssets(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle method to move assets to another project
 void handlePerformAssetAction(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle the type of action specified in actionType
 void handlePerformAssetAction(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle the type of action specified in actionType
 void handleResolveNonConflictingAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle method to revert an asset to a given version
 void handleResolveNonConflictingAssets(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle method to revert an asset
 void handleRevertAsset(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          Handle method to revert an asset to a given version
 void handleRevertAsset(javax.portlet.PortletRequest pRequest, javax.portlet.PortletResponse pResponse)
          Handle method to revert an asset
 void postAddAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality after handleAddAssets is called.
 void postCancelBackgroundTask(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality after handleCancelBackgroundTask is called.
 void postDiscardAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality after handleAddNote is called.
 void postMoveAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality after handleMoveAssets is called.
 void postResolveNonConflictingAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality after handleAddNote is called.
 void postRevertAsset(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality after handleAddNote is called.
 void preAddAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality before handleAddAssets is called.
 void preCancelBackgroundTask(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality before handleCancelBackgroundTask is called.
 void preDiscardAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality before handleDiscardAssets is called.
 void preMoveAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality before handleMoveAssets is called.
 void preResolveNonConflictingAssets(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality before handleDiscardAssets is called.
 void preRevertAsset(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse)
          No-op method meant for subclassing to add user specific functionality before handleDiscardAssets is called.
 void setAsset(java.lang.String string)
           
 void setAssetAction(int pAssetAction)
           
 void setAssetPlaceholder(java.lang.String pPlaceholderName, java.lang.String pAssetURI)
          Set the placeholder value (workflow.contextItems or contextFiles entry) with a specific asset
 void setAssets(java.lang.String[] strings)
           
 void setConfirmationMessage(java.lang.String pConfirmationMessage)
           
 void setMoveAssetsProjectId(java.lang.String pMoveAssetsProjectId)
           
 void setPipeDelimitedAssetURIList(java.lang.String pPipeDelimitedAssetURIList)
           
 void setPlaceholderName(java.lang.String string)
           
 void setSuccessMessage(java.lang.String pSuccessMessage)
          Sets indicates a successful operation
 void setTaskType(int pTaskType)
           
 void setVersion(java.lang.String string)
           
 
Methods inherited from class atg.epub.servlet.PublishingPortletFormHandler
getConfiguration, getCurrentDynamoRequest, getCurrentDynamoResponse, getProcess, getProcessHome, getProcessId, getProcessTaskInfoHome, getProject, getProjectHome, getProjectId, getResource, getResource, getResource, getResource, getWorkflowView, setProcessId, setProjectId, setWorkflowView
 
Methods inherited from class atg.epub.servlet.PortletFormHandler
addFormException, afterGet, afterGet, afterGet, afterSet, afterSet, afterSet, beforeGet, beforeGet, beforeGet, beforeSet, beforeSet, beforeSet, checkFormRedirect, getCheckForValidSession, getFormError, getFormExceptions, getPropertyExceptions, getTransactionDemarcation, handleFormException, handleUncheckedFormException, hasFormExceptions, isEnsureTransaction, isRestorableForm, isRollbackTransaction, isUseForwards, isValidSession, redirectOrForward, resetFormExceptions, setCheckForValidSession, setEnsureTransaction, setRestorableForm, setRollbackTransaction, setTransactionDemarcation, setUseForwards
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION
Class version string


sResolveNonConflictingTaskType

public static int sResolveNonConflictingTaskType

ADD_ASSET_ACTION

public static final int ADD_ASSET_ACTION
See Also:
Constant Field Values

DISCARD_ASSET_ACTION

public static final int DISCARD_ASSET_ACTION
See Also:
Constant Field Values

DEL_ASSET_ACTION

public static final int DEL_ASSET_ACTION
See Also:
Constant Field Values

REVERT_ASSET_ACTION

public static final int REVERT_ASSET_ACTION
See Also:
Constant Field Values

MOVE_ASSET_ACTION

public static final int MOVE_ASSET_ACTION
See Also:
Constant Field Values

RESOLVE_NON_CONFLICTING

public static final int RESOLVE_NON_CONFLICTING
See Also:
Constant Field Values

CANCEL_BACKGROUND_TASK

public static final int CANCEL_BACKGROUND_TASK
See Also:
Constant Field Values
Constructor Detail

ProjectFormHandler

public ProjectFormHandler()
Method Detail

getAssets

public java.lang.String[] getAssets()

setAssets

public void setAssets(java.lang.String[] strings)

getTaskType

public int getTaskType()

setTaskType

public void setTaskType(int pTaskType)

getAsset

public java.lang.String getAsset()

setAsset

public void setAsset(java.lang.String string)

getAssetAction

public int getAssetAction()
Used by handlePerformAssetAction handler to decide which of handleAddAssets or handleDiscardAssets methods to invoke


setAssetAction

public void setAssetAction(int pAssetAction)

getVersion

public java.lang.String getVersion()

setVersion

public void setVersion(java.lang.String string)

getPlaceholderName

public java.lang.String getPlaceholderName()

setPlaceholderName

public void setPlaceholderName(java.lang.String string)

getPipeDelimitedAssetURIList

public java.lang.String getPipeDelimitedAssetURIList()

setPipeDelimitedAssetURIList

public void setPipeDelimitedAssetURIList(java.lang.String pPipeDelimitedAssetURIList)

setMoveAssetsProjectId

public void setMoveAssetsProjectId(java.lang.String pMoveAssetsProjectId)

getMoveAssetsProjectId

public java.lang.String getMoveAssetsProjectId()

setConfirmationMessage

public void setConfirmationMessage(java.lang.String pConfirmationMessage)

getConfirmationMessage

public java.lang.String getConfirmationMessage()

setSuccessMessage

public void setSuccessMessage(java.lang.String pSuccessMessage)
Sets indicates a successful operation


getSuccessMessage

public java.lang.String getSuccessMessage()
Returns indicates a successful operation


getADD_ASSET_ACTION

public int getADD_ASSET_ACTION()

getDISCARD_ASSET_ACTION

public int getDISCARD_ASSET_ACTION()

getDEL_ASSET_ACTION

public int getDEL_ASSET_ACTION()

getREVERT_ASSET_ACTION

public int getREVERT_ASSET_ACTION()

getMOVE_ASSET_ACTION

public int getMOVE_ASSET_ACTION()

getRESOLVE_NON_CONFLICTING

public int getRESOLVE_NON_CONFLICTING()

getCANCEL_BACKGROUND_TASK

public int getCANCEL_BACKGROUND_TASK()

preAddAssets

public void preAddAssets(DynamoHttpServletRequest pRequest,
                         DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality before handleAddAssets is called.


postAddAssets

public void postAddAssets(DynamoHttpServletRequest pRequest,
                          DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality after handleAddAssets is called.


handleAddAssets

public void handleAddAssets(javax.portlet.PortletRequest pRequest,
                            javax.portlet.PortletResponse pResponse)
                     throws javax.servlet.ServletException
Handle method to add an asset to a project. This method first checks to see if the assets property is set. If so, then it will add those assets to the project. If null, then it will check to see if the asset property is null. If not, then it will add that asset to the project.

Throws:
javax.servlet.ServletException

handleAddAssets

public void handleAddAssets(DynamoHttpServletRequest pRequest,
                            DynamoHttpServletResponse pResponse)
                     throws javax.servlet.ServletException
Handle method to add an asset to a project. This method first checks to see if the assets property is set. If so, then it will add those assets to the project. If null, then it will check to see if the asset property is null. If not, then it will add that asset to the project. pje: modified so this method will either add assets to project for modification or deletion

Throws:
javax.servlet.ServletException

preDiscardAssets

public void preDiscardAssets(DynamoHttpServletRequest pRequest,
                             DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality before handleDiscardAssets is called.


postDiscardAssets

public void postDiscardAssets(DynamoHttpServletRequest pRequest,
                              DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality after handleAddNote is called.


handleDiscardAssets

public void handleDiscardAssets(javax.portlet.PortletRequest pRequest,
                                javax.portlet.PortletResponse pResponse)
                         throws javax.servlet.ServletException
Handle method to add a note to a project. Note is added as a history element.

Throws:
javax.servlet.ServletException

handleDiscardAssets

public void handleDiscardAssets(DynamoHttpServletRequest pRequest,
                                DynamoHttpServletResponse pResponse)
                         throws javax.servlet.ServletException
Handle method to add a note to a project. Note is added as a history element.

Throws:
javax.servlet.ServletException

preRevertAsset

public void preRevertAsset(DynamoHttpServletRequest pRequest,
                           DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality before handleDiscardAssets is called.


postRevertAsset

public void postRevertAsset(DynamoHttpServletRequest pRequest,
                            DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality after handleAddNote is called.


handleRevertAsset

public void handleRevertAsset(javax.portlet.PortletRequest pRequest,
                              javax.portlet.PortletResponse pResponse)
                       throws javax.servlet.ServletException
Handle method to revert an asset

Throws:
javax.servlet.ServletException

handleRevertAsset

public void handleRevertAsset(DynamoHttpServletRequest pRequest,
                              DynamoHttpServletResponse pResponse)
                       throws javax.servlet.ServletException
Handle method to revert an asset to a given version

Throws:
javax.servlet.ServletException

preResolveNonConflictingAssets

public void preResolveNonConflictingAssets(DynamoHttpServletRequest pRequest,
                                           DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality before handleDiscardAssets is called.


postResolveNonConflictingAssets

public void postResolveNonConflictingAssets(DynamoHttpServletRequest pRequest,
                                            DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality after handleAddNote is called.


handleResolveNonConflictingAssets

public void handleResolveNonConflictingAssets(javax.portlet.PortletRequest pRequest,
                                              javax.portlet.PortletResponse pResponse)
                                       throws javax.servlet.ServletException
Handle method to revert an asset

Throws:
javax.servlet.ServletException

handleResolveNonConflictingAssets

public void handleResolveNonConflictingAssets(DynamoHttpServletRequest pRequest,
                                              DynamoHttpServletResponse pResponse)
                                       throws javax.servlet.ServletException
Handle method to revert an asset to a given version

Throws:
javax.servlet.ServletException

getTaskName

public static java.lang.String getTaskName(java.lang.String pID,
                                           int pTaskType)

preCancelBackgroundTask

public void preCancelBackgroundTask(DynamoHttpServletRequest pRequest,
                                    DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality before handleCancelBackgroundTask is called.


postCancelBackgroundTask

public void postCancelBackgroundTask(DynamoHttpServletRequest pRequest,
                                     DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality after handleCancelBackgroundTask is called.


handleCancelBackgroundTask

public void handleCancelBackgroundTask(javax.portlet.PortletRequest pRequest,
                                       javax.portlet.PortletResponse pResponse)
                                throws javax.servlet.ServletException
Handle method to revert an asset

Throws:
javax.servlet.ServletException

handleCancelBackgroundTask

public void handleCancelBackgroundTask(DynamoHttpServletRequest pRequest,
                                       DynamoHttpServletResponse pResponse)
                                throws javax.servlet.ServletException
Handle method to revert an asset to a given version

Throws:
javax.servlet.ServletException

preMoveAssets

public void preMoveAssets(DynamoHttpServletRequest pRequest,
                          DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality before handleMoveAssets is called.


postMoveAssets

public void postMoveAssets(DynamoHttpServletRequest pRequest,
                           DynamoHttpServletResponse pResponse)
No-op method meant for subclassing to add user specific functionality after handleMoveAssets is called.


handleMoveAssets

public void handleMoveAssets(javax.portlet.PortletRequest pRequest,
                             javax.portlet.PortletResponse pResponse)
                      throws javax.servlet.ServletException
Handle method to move assets to another project

Throws:
javax.servlet.ServletException

handleMoveAssets

public void handleMoveAssets(DynamoHttpServletRequest pRequest,
                             DynamoHttpServletResponse pResponse)
                      throws javax.servlet.ServletException
Handle method to move assets to another project

Throws:
javax.servlet.ServletException

handlePerformAssetAction

public void handlePerformAssetAction(javax.portlet.PortletRequest pRequest,
                                     javax.portlet.PortletResponse pResponse)
                              throws javax.servlet.ServletException
Handle the type of action specified in actionType

Throws:
javax.servlet.ServletException

handlePerformAssetAction

public void handlePerformAssetAction(DynamoHttpServletRequest pRequest,
                                     DynamoHttpServletResponse pResponse)
                              throws javax.servlet.ServletException
Handle the type of action specified in actionType

Throws:
javax.servlet.ServletException

setAssetPlaceholder

public void setAssetPlaceholder(java.lang.String pPlaceholderName,
                                java.lang.String pAssetURI)
Set the placeholder value (workflow.contextItems or contextFiles entry) with a specific asset


clearAssetPlaceholder

public void clearAssetPlaceholder(java.lang.String[] assets)
Clears any placeholder values that were held by assets being discarded


getReferenceWorkingVersions

protected java.util.Set getReferenceWorkingVersions(RepositoryItem pItem,
                                                    Workspace pWorkspace)
                                             throws RepositoryException,
                                                    VersionException
Given a RepositoryItem, return a list of reference repository in the Workspace. Only checks reference items when pItem is a RepositoryVersionItem.

Parameters:
pItem -
pWorkspace -
Returns:
Throws:
RepositoryException
VersionException