|
BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--weblogic.servlet.jsp.JspBase | +--com.beasys.commerce.axiom.jsp.JspBase
Acts as a base class for all JSP pages that use the Flow Manager.
Prescribes methods which facilitate p13n run-time operation. Allows access
to the FlowManager
URI, the application's working
directory, the home page, and the current page.
Also, facilitates management of the application's run-time session, by providing
convenience methods for setting and getting session values, and
setting and getting JSP destinations. Implements several constants
interfaces to reduce the burden of constant referencing by JSP pages.
Field Summary | |
protected static boolean |
debug
Whether debug mode is on. |
static java.lang.String |
DESTINATION_TAG
A property name denoting the destination to be used with form submission. |
Fields inherited from class weblogic.servlet.jsp.JspBase |
_servletConfig |
Constructor Summary | |
JspBase()
|
Method Summary | |
static java.lang.String |
cnvrtSC(java.lang.String theInpStr)
Given a string, substitute HTML entities for HTML special characters. |
static java.lang.String |
createURL(javax.servlet.http.HttpServletRequest aRequest,
java.lang.String destination,
java.lang.String parameters)
Creates a FlowManager application URL from the given request. |
static java.lang.String |
escapeQuotes(java.lang.String input)
Escape single-quotes from a string to make them javascript-friendly (this also runs the string through cnvrtSC) |
static java.lang.String |
fixupRelativeURL(java.lang.String aURL,
javax.servlet.http.HttpServletRequest aRequest)
With the system using jsp:forward the relative directories may not be set employed correctly. |
static java.lang.String |
getCurrentPage(javax.servlet.http.HttpServletRequest aRequest)
Returns the currently active FlowManager application page. |
static java.lang.String |
getDefaultDestination(javax.servlet.http.HttpServletRequest aRequest)
Get the default destination specified in the registration. |
static java.lang.String |
getDefaultSuccessor(javax.servlet.http.HttpServletRequest aRequest)
Get the default succssor (group) that was specified in the servlet registration. |
static java.lang.String |
getHomePage(javax.servlet.http.HttpServletRequest aRequest)
Retrieves the FlowManger application home page specified by the start-up parameters for the p13n app. |
static boolean |
getLoggedIn(javax.servlet.http.HttpServletRequest aRequest)
Indicates whether a user is currently logged into the FlowManager app. |
static java.lang.String |
getRepositoryDirectory(javax.servlet.http.HttpServletRequest aRequest)
Get the Portal repository directory specified in the registration. |
static java.lang.String |
getRequestURI(javax.servlet.http.HttpServletRequest aRequest)
Retrieves the request URI. |
static javax.servlet.ServletConfig |
getServletConfig(javax.servlet.http.HttpServletRequest aRequest)
Get the servlet config from the request |
static java.lang.Object |
getSessionValue(java.lang.String aName,
javax.servlet.http.HttpServletRequest aRequest)
Retrieves a session value. |
static java.lang.String |
getTrafficURI(javax.servlet.http.HttpServletRequest aRequest)
Retrieves the URI of the FlowManager . |
static java.lang.String |
getTrafficURINoContext(javax.servlet.http.HttpServletRequest aRequest)
Get traffic URI with no context. |
static java.lang.String |
getWorkingDirectory(javax.servlet.http.HttpServletRequest aRequest)
Get the working directory specified in the registration. |
static java.lang.String |
pathFromRequest(javax.servlet.http.HttpServletRequest aRequest)
Get the fully-qualified path of the request URI. |
static void |
putSessionValue(java.lang.String aName,
java.lang.Object aValue,
javax.servlet.http.HttpServletRequest aRequest)
Sets a session value. |
static java.lang.String |
reconcileFile(javax.servlet.http.HttpServletRequest aRequest,
java.lang.String aURL)
Check to see if the file exists in the working directory of the FlowManager application. |
static java.lang.String |
reconcileFile(javax.servlet.http.HttpServletRequest aRequest,
java.lang.String aURL,
boolean addWebappContext)
Call the reconcileFile method specifying whether any webapp context should be included. |
static void |
removeSessionValue(java.lang.String aName,
javax.servlet.http.HttpServletRequest aRequest)
Removes a session value. |
static void |
setAlternateDestination(javax.servlet.http.HttpServletRequest req,
java.lang.String dest)
Deprecated. use setOverrideDestination |
static void |
setLoggedIn(javax.servlet.http.HttpServletRequest aRequest,
javax.servlet.http.HttpServletResponse aResponse,
boolean aBool)
Sets the logged-in state for this FlowManager application. |
static void |
setOverrideDestination(javax.servlet.http.HttpServletRequest req,
java.lang.String dest)
Sets the alternate forward variable. |
static void |
setSessionValue(java.lang.String aName,
java.lang.Object aValue,
javax.servlet.http.HttpServletRequest aRequest)
Sets a session value. |
static void |
setSuccessor(java.lang.String aSuccessor,
javax.servlet.http.HttpServletRequest aRequest)
Takes a group name and puts it into the session as the value of the SERVICEMANAGER_SUCCESSOR |
static void |
setUser(java.lang.String aUser,
javax.servlet.http.HttpServletRequest aRequest)
Takes a user name and puts it into the session as the value of the SERVICEMANAGER_USER |
static void |
setUserAndSuccessor(java.lang.String aUser,
java.lang.String aSuccessor,
javax.servlet.http.HttpServletRequest aRequest)
Takes a user name and a group name and puts them into the session as the values of the SERVICEMANAGER_USER and SERVICEMANAGER_SUCCESSOR, respectively |
Methods inherited from class weblogic.servlet.jsp.JspBase |
_jspService,
destroy,
getServletConfig,
getServletInfo,
init,
jspDestroy,
jspInit,
service |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
protected static final boolean debug
public static final java.lang.String DESTINATION_TAG
Constructor Detail |
public JspBase()
Method Detail |
public static java.lang.String getTrafficURI(javax.servlet.http.HttpServletRequest aRequest)
FlowManager
.aRequest
- the javax.servlet.http.HttpServletRequest
from which
the FlowManager
is obtained.String
the URI of the FlowManager
.
If you are not using a Service Manager, then this will return null;public static java.lang.String getTrafficURINoContext(javax.servlet.http.HttpServletRequest aRequest)
aRequest
- String
public static java.lang.String getWorkingDirectory(javax.servlet.http.HttpServletRequest aRequest)
aRequest
- javax.servlet.http.HttpServletRequest
from which
the FlowManager
is obtained.String
the value of the working directory of the
current p13n app instantiationpublic static java.lang.String getRepositoryDirectory(javax.servlet.http.HttpServletRequest aRequest)
aRequeset
- javax.servlet.http.HttpServletRequest
from which
the FlowManager
is obtained.String
the value of the working directory of the
current portal instantiationpublic static java.lang.String getDefaultDestination(javax.servlet.http.HttpServletRequest aRequest)
the
- javax.servlet.http.HttpServletRequest
corresponding
to the FlowManager
String
the default destination of the p13n app instantiationpublic static javax.servlet.ServletConfig getServletConfig(javax.servlet.http.HttpServletRequest aRequest)
the
- javax.servlet.http.HttpServletRequest
corresponding
to the FlowManager
ServletConfig
the current request's configurationpublic static java.lang.String getRequestURI(javax.servlet.http.HttpServletRequest aRequest)
null
or empty, the request.getRequestURI() method wil be
called.the
- javax.servlet.http.HttpServletRequest
for which the URI
is soughtpublic static java.lang.String pathFromRequest(javax.servlet.http.HttpServletRequest aRequest)
aRequest
- the javax.servlet.http.HttpServletRequest
for which
the fully-qualified path is soughtString
the fully qualified path from the requestpublic static java.lang.String createURL(javax.servlet.http.HttpServletRequest aRequest, java.lang.String destination, java.lang.String parameters)
aRequest
- The javax.servlet.http.HttpServletRequest
used to create the full URL.destination
- The desired destination. If the destination is not fully qualified (assumed relative), it will
query the request to prepend the path. NOTE: do not include a query string in the destination.parameters
- The parameters. These will be appended to the URL.String
the created URLpublic static java.lang.String fixupRelativeURL(java.lang.String aURL, javax.servlet.http.HttpServletRequest aRequest)
aURL
- the url to fixup.aRequest
- the associated request.String
the fixed-up URL.public static java.lang.String reconcileFile(javax.servlet.http.HttpServletRequest aRequest, java.lang.String aURL, boolean addWebappContext)
aURL
- the file to check for. This can be a fully qualified url, in
which case nothing happens.aRequest
- the request, because we need the repository directory as well
as the hashmap associated to the current servlet.addWebappContext
- a flag indicating whether to add or suppress any
available webapp contextpublic static java.lang.String reconcileFile(javax.servlet.http.HttpServletRequest aRequest, java.lang.String aURL)
aURL
- the file to check for. This can be a fully qualified url, in
which case nothing happens.aRequest
- the request, because we need the repository directory as well
as the hashmap associated to the current servlet.public static java.lang.String getHomePage(javax.servlet.http.HttpServletRequest aRequest)
aRequest
- the http.servlet.http.HttpServletRequest
from which
p13n app information is obtainedString
the FlowManager home pagepublic static java.lang.String getCurrentPage(javax.servlet.http.HttpServletRequest aRequest)
aRequest
- the http.servlet.http.HttpServletRequest
from which
FlowManager information is obtainedString
the current p13n app pagepublic static void setAlternateDestination(javax.servlet.http.HttpServletRequest req, java.lang.String dest)
DESTINATION_TAG
property upon form submission.req
- the javax.servlet.http.HttpServletRequest
associated with
the form submissiondestination
- the JSP page which ultimate processes the requestpublic static void setOverrideDestination(javax.servlet.http.HttpServletRequest req, java.lang.String dest)
DESTINATION_TAG
property upon form submission.req
- the javax.servlet.http.HttpServletRequest
associated with
the form submissiondest
- the JSP page which ultimate processes the requestpublic static void setLoggedIn(javax.servlet.http.HttpServletRequest aRequest, javax.servlet.http.HttpServletResponse aResponse, boolean aBool)
aRequest
- the javax.servlet.http.HttpServletRequest
used
to retrieve the session for updatethe
- corresponding javax.servlet.http.HttpServletResponse
aBool
- designates the true
or false
logged-in valuepublic static boolean getLoggedIn(javax.servlet.http.HttpServletRequest aRequest)
the
- FlowManager app javax.servlet.http.HttpServletRequest
boolean
whether a user is logged inpublic static java.lang.Object getSessionValue(java.lang.String aName, javax.servlet.http.HttpServletRequest aRequest)
FlowManager
to avoid naming collisions
when multiple FlowManager
objects share the same
session.aName
- the name of the session property whose value is soughtaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedObject
the new property valuepublic static void setSessionValue(java.lang.String aName, java.lang.Object aValue, javax.servlet.http.HttpServletRequest aRequest)
FlowManager
to avoid naming collisions
when multiple FlowManager
objects share the same
session.aName
- the name of the session property whose value is to be setaValue
- the new property valueaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedpublic static void putSessionValue(java.lang.String aName, java.lang.Object aValue, javax.servlet.http.HttpServletRequest aRequest)
FlowManager
to avoid naming collisions
when multiple FlowManager
objects share the same
session.aName
- the name of the session property whose value is to be setaValue
- the new property valueaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedpublic static void removeSessionValue(java.lang.String aName, javax.servlet.http.HttpServletRequest aRequest)
FlowManager
to avoid naming collisions
when multiple FlowManager
objects share the same
session.aName
- the name of the session property to be removedaValue
- the new property valueaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedpublic static java.lang.String cnvrtSC(java.lang.String theInpStr)
theInpStr
- the string to be convertedString
the string with special chars translatedpublic static void setUser(java.lang.String aUser, javax.servlet.http.HttpServletRequest aRequest)
aUser
- the user nameaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedpublic static void setSuccessor(java.lang.String aSuccessor, javax.servlet.http.HttpServletRequest aRequest)
aSuccessor
- the group nameaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedpublic static void setUserAndSuccessor(java.lang.String aUser, java.lang.String aSuccessor, javax.servlet.http.HttpServletRequest aRequest)
aUser
- the user nameaSuccessor
- the group nameaRequest
- the javax.servlet.http.HttpServletRequest
from
which the session is obtainedpublic static java.lang.String getDefaultSuccessor(javax.servlet.http.HttpServletRequest aRequest)
aRequest.
- public static java.lang.String escapeQuotes(java.lang.String input)
intput
- the String to escape
|
BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |