|
||||||||||
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.service.email.EmailFormHandler
atg.projects.store.profile.email.StoreEmailFormHandler
public class StoreEmailFormHandler
This formhandler extends the OOTB EmailFormHandler so as to capture the users name when the email is sent.
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string. |
Fields inherited from class atg.service.email.EmailFormHandler |
---|
MSG_EMPTY_MESSAGE, MSG_INVALID_RECIPIENT_EMAIL, MSG_INVALID_SENDER_EMAIL, MSG_NO_EMAIL_HOST_NAME, MSG_NO_RECIPIENT_EMAIL, MSG_NO_SENDER_EMAIL |
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 | |
---|---|
StoreEmailFormHandler()
|
Method Summary | |
---|---|
java.lang.String |
getCustomerServiceEmailAddress()
|
java.lang.String |
getEmail()
|
java.lang.String |
getFirstName()
|
java.lang.String |
getLastName()
|
protected boolean |
sendMail(atg.servlet.DynamoHttpServletRequest pRequest,
atg.servlet.DynamoHttpServletResponse pResponse)
Customizes the send operation. |
void |
setCustomerServiceEmailAddress(java.lang.String pCustomerServiceEmailAddress)
|
void |
setEmail(java.lang.String pEmail)
|
void |
setFirstName(java.lang.String pFirstName)
|
void |
setLastName(java.lang.String pLastName)
|
protected boolean |
validate(atg.servlet.DynamoHttpServletRequest pRequest,
atg.servlet.DynamoHttpServletResponse pResponse)
Validate the email's fields for correctness. |
Methods inherited from class atg.service.email.EmailFormHandler |
---|
getBody, getDefaultLocale, getEmailSenderService, getRecipient, getSender, getSendErrorURL, getSendSuccessURL, getSubject, getUserLocale, handleSendEmail, isUseRequestLocale, setBody, setDefaultLocale, setEmailSenderService, setRecipient, setSender, setSendErrorURL, setSendSuccessURL, setSubject, setUseRequestLocale, toString |
Methods inherited from class atg.droplet.GenericFormHandler |
---|
addFormException, addUncheckedFormException, afterSet, beforeSet, checkFormRedirect, createFormSubmissionMessage, getCancelURL, getCheckForValidSession, getFormError, getFormExceptions, getFormName, getMessagePort, getMessageSource, getMessageType, getPropertyExceptions, getSendMessages, getUncheckedFormExceptions, handleCancel, handleFormException, handleUncheckedFormException, 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, beforeGet |
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, wait, wait, wait |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
Constructor Detail |
---|
public StoreEmailFormHandler()
Method Detail |
---|
public java.lang.String getFirstName()
public void setFirstName(java.lang.String pFirstName)
pFirstName
- - first name.public java.lang.String getLastName()
public void setLastName(java.lang.String pLastName)
pLastName
- - last name.public java.lang.String getCustomerServiceEmailAddress()
public void setCustomerServiceEmailAddress(java.lang.String pCustomerServiceEmailAddress)
pCustomerServiceEmailAddress
- - customer service
e-mail address.public java.lang.String getEmail()
public void setEmail(java.lang.String pEmail)
pEmail
- - email.protected boolean sendMail(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
sender: full name (id) <email>s
recipient: customer_svc@atg.com
The full name and email address come from the user input. The recipient is the value specified in the properties file for the customerServiceEmailAddress.
The EmailFormHandler
'ssendMail()
is then
called normally.
sendMail
in class atg.service.email.EmailFormHandler
pRequest
- DynamoHttpServletRequestpResponse
- DynamoHttpServletResponse
javax.servlet.ServletException
- if there was an error while executing the code
java.io.IOException
- if there was an error with servlet ioprotected boolean validate(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
Currently only checks that the sender and recipient addresses contain a
'@' and that both the subject andd body aren't empty.
This protected method is intended to be overriden by a subclass to
provide customized error checking.
validate
in class atg.service.email.EmailFormHandler
pRequest
- DynamoHttpServletRequestpResponse
- DynamoHttpServletResponse
javax.servlet.ServletException
- if there was an error while executing the code
java.io.IOException
- if there was an error with servlet io
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |