|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.tirsen.angkor.Application
The main controller of an application, typically first class extended when implementing an application in Angkor. There is one instance of this for each session. Responsibilities include:
Constructor Summary | |
Application()
|
Method Summary | |
void |
afterRequest(RenderContext context)
|
void |
allocateUniqueID(java.lang.String id,
View view)
|
void |
beforeRequest(RenderContext context)
|
Pipeline |
createBasicPipeline()
Creates the basic pipeline with the exception of a render valve. |
protected Pipeline |
createDefaultPipeline()
|
Pipeline |
createPrerenderPipeline()
Creates a pipeline that prerenders all currently registered components. |
Pipeline |
createRenderPipeline(ViewFactory factory)
Creates the default processing pipeline. |
void |
destroy()
|
static Application |
getApplication()
Returns the application of the currently executing pipeline. |
ViewFactory |
getComponent(java.lang.String name)
|
java.util.Map |
getComponentsToPrerender()
This is used by the PrerenderValve and is not part of the public API. |
java.lang.Throwable |
getError()
|
Page |
getPage(java.lang.String pageName)
|
java.util.Collection |
getParsingComponents()
Public for unit tests only, maybe it's time to move to JUnitX soon. |
java.lang.String |
getWindowTitle()
Override to provide a title rendered by the angkor:header-tag. |
void |
handleError(java.lang.Throwable e)
|
void |
init()
Overriding method needs to call this method. |
protected void |
initDefaultPropertyEditors()
|
protected void |
initPrerenderedComponents()
|
java.util.Iterator |
iterateParsingComponents()
Returns a tread-safe iterator of the parsing components. |
java.lang.String |
nextUniqueID()
|
void |
process(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
void |
registerComponent(java.lang.String name,
ViewFactory factory)
Registers a new component. |
void |
registerLink(java.lang.String name,
ViewFactory originalBinding)
|
void |
registerPage(java.lang.String name,
Page page)
|
void |
registerParsingComponent(View view)
|
void |
registerPrerenderComponent(java.lang.String name,
View component)
Registers a new component. |
void |
relink(java.lang.String name,
java.lang.String target)
Relinks a link to a named view. |
void |
relink(java.lang.String name,
ViewFactory target)
Relinks a link. |
void |
resetParsingComponents()
|
void |
valueBound(javax.servlet.http.HttpSessionBindingEvent event)
|
void |
valueUnbound(javax.servlet.http.HttpSessionBindingEvent event)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Application()
Method Detail |
public java.lang.Throwable getError()
public void handleError(java.lang.Throwable e)
public ViewFactory getComponent(java.lang.String name)
public void registerComponent(java.lang.String name, ViewFactory factory)
java.lang.IllegalStateException
- if that component has already been registered.public void registerPrerenderComponent(java.lang.String name, View component)
java.lang.IllegalStateException
- if that component has already been registered.public void registerLink(java.lang.String name, ViewFactory originalBinding)
public void relink(java.lang.String name, ViewFactory target)
public void relink(java.lang.String name, java.lang.String target)
public void init()
public void destroy()
public void valueBound(javax.servlet.http.HttpSessionBindingEvent event)
valueBound
in interface javax.servlet.http.HttpSessionBindingListener
public void valueUnbound(javax.servlet.http.HttpSessionBindingEvent event)
valueUnbound
in interface javax.servlet.http.HttpSessionBindingListener
protected void initPrerenderedComponents()
protected void initDefaultPropertyEditors()
public void beforeRequest(RenderContext context) throws java.io.IOException
java.io.IOException
public void afterRequest(RenderContext context) throws java.io.IOException
java.io.IOException
public Pipeline createRenderPipeline(ViewFactory factory)
public Pipeline createPrerenderPipeline()
public Pipeline createBasicPipeline()
protected Pipeline createDefaultPipeline()
public void resetParsingComponents()
public java.util.Iterator iterateParsingComponents()
public java.util.Collection getParsingComponents()
public void registerParsingComponent(View view)
public java.lang.String nextUniqueID()
public void allocateUniqueID(java.lang.String id, View view)
public java.util.Map getComponentsToPrerender() throws java.lang.Exception
PrerenderValve
and is not part of the public API.
String
-> ViewFactory
map containing the components to prerender.
java.lang.Exception
public static Application getApplication()
public java.lang.String getWindowTitle()
public void registerPage(java.lang.String name, Page page)
public void process(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws java.lang.Exception
java.lang.Exception
public Page getPage(java.lang.String pageName)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |