|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.struts.action.Action
com.konakart.actions.BaseAction
public class BaseAction
Base Action for KonaKart application. All of the other action classes extend this class.
| Field Summary | |
|---|---|
protected org.apache.commons.logging.Log |
log
The Log instance for this application. |
protected static java.lang.String |
loginForward
|
| Fields inherited from class org.apache.struts.action.Action |
|---|
defaultLocale, servlet |
| Constructor Summary | |
|---|---|
BaseAction()
|
|
| Method Summary | |
|---|---|
protected org.apache.struts.action.ActionForward |
checkSSL(javax.servlet.http.HttpServletRequest request,
int custId,
boolean forceSSL)
Determines whether we are using SSL or not. |
protected void |
clearErrors(javax.servlet.http.HttpServletRequest request)
Method called to clear the current error stack. |
protected org.apache.struts.action.ActionForward |
getForward(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request,
java.lang.Exception e,
java.lang.String cause,
java.lang.String message,
java.lang.String forward)
If the application sends us a KKException with the cause equal to a more detailed exception such as KKPasswordDoesntMatchException, sometimes the application has to be able to detect this so that it can handle the exception by sending an error message back to the screen. |
protected KKAppEng |
getKKAppEng(javax.servlet.http.HttpServletRequest request)
Sets the variable kkAppEng to the KKAppEng instance saved in the session. |
protected java.lang.String |
handleException(javax.servlet.http.HttpServletRequest request,
java.lang.Exception e)
A common method that contains the code to deal with exceptions |
protected boolean |
isOnePageCheckout(KKAppEng kkAppEng)
Returns true if configured for one page checkout |
protected int |
loggedIn(KKAppEng kkAppEng,
java.lang.String forwardAfterLogin)
Checks to see whether we are logged in. |
protected boolean |
runningInPortal(KKAppEng kkAppEng)
Returns true if we are running in a portal |
| Methods inherited from class org.apache.struts.action.Action |
|---|
addErrors, addMessages, execute, execute, generateToken, getDataSource, getDataSource, getErrors, getLocale, getMessages, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, resetToken, saveErrors, 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 |
|---|
protected org.apache.commons.logging.Log log
Log instance for this application.
protected static final java.lang.String loginForward
| Constructor Detail |
|---|
public BaseAction()
| Method Detail |
|---|
protected KKAppEng getKKAppEng(javax.servlet.http.HttpServletRequest request)
throws KKAppException,
com.konakart.app.KKException
request -
com.konakart.app.KKException
KKAppException
protected java.lang.String handleException(javax.servlet.http.HttpServletRequest request,
java.lang.Exception e)
request - e -
protected int loggedIn(KKAppEng kkAppEng,
java.lang.String forwardAfterLogin)
throws com.konakart.app.KKException
kkAppEng - The KonaKart client engine instanceforwardAfterLogin - tells us which page to forward to after login.
com.konakart.app.KKExceptionprotected void clearErrors(javax.servlet.http.HttpServletRequest request)
request -
protected org.apache.struts.action.ActionForward getForward(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request,
java.lang.Exception e,
java.lang.String cause,
java.lang.String message,
java.lang.String forward)
mapping - request - e - The exception that has been capturedcause - The name of the cause Exception to look for i.e. KKPasswordDoesntMatchExceptionmessage - The message to send out to the applicationforward - The forward if we detect the cause
protected org.apache.struts.action.ActionForward checkSSL(javax.servlet.http.HttpServletRequest request,
int custId,
boolean forceSSL)
throws com.konakart.app.KKException
request - custId - The customer idforceSSL - Set to true if we should force SSL.
com.konakart.app.KKExceptionprotected boolean runningInPortal(KKAppEng kkAppEng)
kkAppEng -
protected boolean isOnePageCheckout(KKAppEng kkAppEng)
kkAppEng -
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||