|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--tomp.ext.Application | +--tomp.ext.servlet.ServletApplication
Class ServletApplication is an extension of the simple Application.
Calls actions when the app. is initialized, when web user creates a new HttpSession, and also on normal HttpServletRequest event.
Also, on servlet shutdown (Servlet.destroy() method) an action is created and launched (EndApplicationAction).
User can call any previously registered action by specifying the name in the action request parameter.
Field Summary | |
protected ServletAction |
initAction
|
protected javax.servlet.http.HttpServlet |
servlet
|
Fields inherited from class tomp.ext.Application |
LOGFILE, NONE, STDERR |
Constructor Summary | |
ServletApplication(javax.servlet.http.HttpServlet servlet)
Initializes the superclass (Application) object, i.e. all the standard settings regarding XML,... |
Method Summary | |
void |
destroy()
Represents the HttpServlet.destroy() method that forwards the destroy() event to this method. |
javax.servlet.http.HttpServlet |
getServlet()
|
void |
init()
Creates the StartApplicationAction and runs it. |
protected StartApplicationAction |
makeInitAction(java.lang.Class id,
ServletApplication app,
javax.servlet.http.HttpServlet servlet)
Creates a StartApplicationAction with specified params. |
protected StartApplicationAction |
makeInitAction(ServletApplication app,
javax.servlet.http.HttpServlet servlet)
Creates a StartApplicationAction with specified params. |
protected RequestAction |
makeRequestAction(java.lang.Class id,
ServletAction previous,
javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
Creates a RequestAction with specified params. |
protected RequestAction |
makeRequestAction(ServletAction previous,
javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
Creates a RequestAction with specified params. |
protected StartSessionAction |
makeStartSessionAction(java.lang.Class id,
ServletAction previous,
javax.servlet.http.HttpSession session)
Creates a StartSessionAction with specified params. |
protected StartSessionAction |
makeStartSessionAction(ServletAction previous,
javax.servlet.http.HttpSession session)
Creates a StartSessionAction with specified params. |
void |
service(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
Actually perfoms the HttpServlet.service(req, res) method that is forwarded to this method by the extended EXTServlet.service(req, res) The method creates and launches actions according to the: HttpSession bound to the request and request parameter action |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected javax.servlet.http.HttpServlet servlet
protected ServletAction initAction
Constructor Detail |
public ServletApplication(javax.servlet.http.HttpServlet servlet)
Method Detail |
public javax.servlet.http.HttpServlet getServlet()
public void init() throws EXTException
EXTException
public void destroy() throws EXTException
EXTException
public void service(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) throws javax.servlet.ServletException, java.io.IOException
javax.servlet.ServletException
java.io.IOException
protected RequestAction makeRequestAction(java.lang.Class id, ServletAction previous, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) throws EXTException
id
- the class object of the requested RequestAction classprevious
- previous actionreq
- HttpServletRequestres
- HttpServletResponse
EXTException
Application.getActionClass(java.lang.Class)
protected RequestAction makeRequestAction(ServletAction previous, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) throws EXTException
previous
- previous actionreq
- HttpServletRequestres
- HttpServletResponse
EXTException
Application.getActionClass(java.lang.Class)
protected StartSessionAction makeStartSessionAction(java.lang.Class id, ServletAction previous, javax.servlet.http.HttpSession session) throws EXTException
id
- the class object of the requested StartSessionAction classprevious
- previous action
EXTException
Application.getActionClass(java.lang.Class)
protected StartSessionAction makeStartSessionAction(ServletAction previous, javax.servlet.http.HttpSession session) throws EXTException
previous
- previous action
EXTException
Application.getActionClass(java.lang.Class)
protected StartApplicationAction makeInitAction(java.lang.Class id, ServletApplication app, javax.servlet.http.HttpServlet servlet) throws EXTException
id
- the class object of the requested StartApplicationAction class
EXTException
Application.getActionClass(java.lang.Class)
protected StartApplicationAction makeInitAction(ServletApplication app, javax.servlet.http.HttpServlet servlet) throws EXTException
EXTException
Application.getActionClass(java.lang.Class)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |