|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectatg.nucleus.logging.VariableArgumentApplicationLoggingImpl
atg.nucleus.GenericService
atg.droplet.EmptyFormHandler
atg.droplet.GenericFormHandler
atg.droplet.TransactionalFormHandler
atg.web.formhandlers.ApplicationFormHandler
atg.svc.ui.formhandlers.ServiceFormHandler
public class ServiceFormHandler
Base FormHandler for service applications that adds some additional error handling and transaction management. By default transactions are enabled for all setters/handle method calls on the form. The transaction encapsulates all setter and handle calls together and then ends the transaction in afterSet. Also, by default transactions are not rolled back.
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string |
static java.lang.String |
PERFMON_OP_FORM_HANDLER
|
Fields inherited from class atg.web.formhandlers.ApplicationFormHandler |
---|
EQUALS, PARAM_DELIMITER, QUERY_DELIMITER, STATUS_ERROR_REDIRECT, STATUS_ERROR_STAY, STATUS_SUCCESS |
Fields inherited from class atg.droplet.GenericFormHandler |
---|
PARAM_DEFER_FORWARD_OR_REDIRECT, PARAM_USE_FORWARDS |
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 | |
---|---|
ServiceFormHandler()
|
Method Summary | |
---|---|
void |
handleUncheckedFormException(java.lang.Throwable exception,
atg.servlet.DynamoHttpServletRequest pRequest,
atg.servlet.DynamoHttpServletResponse pResponse)
Logs all unhandled exceptions if the formhandler is configured to do so in the loggingUncheckedError property. |
boolean |
isLoggingUncheckedException()
Gets the value of the loggingUncheckedException property. |
boolean |
isRollbackTransactionOnFormError()
Gets the isRollbackTransactionOnFormError property. |
protected boolean |
isTransactionMarkedAsRollback()
Returns true if there has been a form error or unchecked exception thrown in the handle method so that the transaction can be been marked for rollback. |
void |
processException(java.lang.Exception pException,
java.lang.String pMsgId,
atg.servlet.DynamoHttpServletRequest pRequest,
atg.servlet.DynamoHttpServletResponse pResponse)
Override processException to force all exceptions to be logged if isLoggingError=true |
void |
processException(java.lang.Exception pException,
java.lang.String pMsgId,
atg.servlet.DynamoHttpServletRequest pRequest,
atg.servlet.DynamoHttpServletResponse pResponse,
java.lang.Object[] pParam)
Override processException to force all exceptions to be logged if isLoggingError=true |
void |
setLoggingUncheckedException(boolean pLoggingUncheckedException)
Sets the value of the loggingUncheckedException property. |
void |
setRollbackTransactionOnFormError(boolean pRollbackTransactionOnFormError)
Set the isRollbackTransactionOnFormError property. |
Methods inherited from class atg.web.formhandlers.ApplicationFormHandler |
---|
addParameterToURLString, beforeGet, beforeSet, checkFormError, checkFormRedirect, checkFormSuccess, formHandlerBeforeGet, formHandlerBeforeSet, formHandlerInit, getErrorURL, getRedirectDelayMS, getString, getString, getString, getSuccessURL, getUserMessagesResourceBundle, handleCancel, processException, processException, processExceptionAndLog, processExceptionAndLog, redirect, setErrorURL, setRedirectDelayMS, setSuccessURL, setUserMessagesResourceBundle |
Methods inherited from class atg.droplet.TransactionalFormHandler |
---|
afterSet, commitTransaction, getTransactionDemarcation, getTransactionStatus, isEnsureTransaction, isRollbackTransaction, isRollbackTransactionOnUnhandledException, setEnsureTransaction, setRollbackTransaction, setRollbackTransactionOnUnhandledException, setTransactionDemarcation |
Methods inherited from class atg.droplet.GenericFormHandler |
---|
addFormException, addUncheckedFormException, createFormSubmissionMessage, getCancelURL, getCheckForValidSession, getFormError, getFormExceptions, getFormName, getMessagePort, getMessageSource, getMessageType, getPropertyExceptions, getSendMessages, getUncheckedFormExceptions, handleFormException, hasUncheckedFormExceptions, isDeferForwardsAndRedirects, isRestorableForm, isUseForwards, isValidSession, redirectOrForward, resetFormExceptions, setCancelURL, setCheckForValidSession, setDeferForwardsAndRedirects, setFormName, setMessagePort, setMessageSource, setMessageType, setRestorableForm, setSendMessages, setUseForwards |
Methods inherited from class atg.droplet.EmptyFormHandler |
---|
afterGet |
Methods inherited from class atg.nucleus.GenericService |
---|
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService |
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl |
---|
vlogDebug, vlogDebug, vlogDebug, vlogDebug, 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 |
---|
public static java.lang.String CLASS_VERSION
public static final java.lang.String PERFMON_OP_FORM_HANDLER
Constructor Detail |
---|
public ServiceFormHandler()
Method Detail |
---|
public boolean isRollbackTransactionOnFormError()
public void setRollbackTransactionOnFormError(boolean pRollbackTransactionOnFormError)
pRollbackTransactionOnFormError
- true if the transaction should rollback when there are form errors.public boolean isLoggingUncheckedException()
public void setLoggingUncheckedException(boolean pLoggingUncheckedException)
pLoggingUncheckedException
- true if unchecked exceptions passed to handleUncheckedException should be logged.public void handleUncheckedFormException(java.lang.Throwable exception, atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
handleUncheckedFormException
in interface atg.droplet.DropletFormHandler
handleUncheckedFormException
in class atg.droplet.GenericFormHandler
exception
- The unchecked exception to log.pRequest
- The requestpResponse
- The responsepublic void processException(java.lang.Exception pException, java.lang.String pMsgId, atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
pException
- pMsgId
- pRequest
- pResponse
- public void processException(java.lang.Exception pException, java.lang.String pMsgId, atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse, java.lang.Object[] pParam)
pException
- pMsgId
- pRequest
- pResponse
- pParam
- protected boolean isTransactionMarkedAsRollback()
isTransactionMarkedAsRollback
in class atg.droplet.TransactionalFormHandler
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |