|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ideo.sweetdevria.page.Page
public class Page
Field Summary | |
---|---|
static java.lang.String |
REQ_PAGE_ID
|
static java.lang.String |
SESS_PAGE_ID
|
Constructor Summary | |
---|---|
Page(java.lang.String _id,
javax.servlet.http.HttpSession _session)
|
Method Summary | |
---|---|
void |
addModel(IModel model)
Add a model as a part of this page+session |
java.lang.String |
getId()
|
IModel |
getModel(java.lang.String id)
Return the Model corresponding to this id |
ModelRegistry |
getModelRegistry()
Return the model registry for this page, with some APIs describing the state of the models |
static java.lang.String |
getPageId(javax.servlet.http.HttpSession _sess)
|
static java.lang.String |
getPageId(javax.servlet.ServletRequest _req)
|
javax.servlet.http.HttpSession |
getSession()
|
static java.lang.String |
initPageId(javax.servlet.http.HttpServletRequest request,
java.lang.String pageName)
Init a page id for the current http request First look up if one exists is the request, then if one is specified in the page, then if the session one should be propagated, and finally generate one if all the previous check fail |
static java.lang.String |
initPageId(javax.servlet.jsp.PageContext pageContext,
java.lang.String pageName)
Init a page id for the current page context First look up if one exists is the request, then if one is specified in the page, then if the session one should be propagated, and finally generate one if all the previous check fail |
static java.lang.String |
initPageId(javax.servlet.ServletRequest request,
javax.servlet.http.HttpSession session,
java.lang.String pageName)
Init a page id for this couple request/session First look up if one exists is the request, then if one is specified in the page, then if the session one should be propagated, and finally generate one if all the previous check fail |
void |
setId(java.lang.String _id)
|
static void |
setPageId(javax.servlet.ServletRequest request,
javax.servlet.http.HttpSession session,
java.lang.String _idPage)
Set a page id for the corresponding request and session |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String REQ_PAGE_ID
public static final java.lang.String SESS_PAGE_ID
Constructor Detail |
---|
public Page(java.lang.String _id, javax.servlet.http.HttpSession _session)
Method Detail |
---|
public java.lang.String getId()
public void setId(java.lang.String _id)
public javax.servlet.http.HttpSession getSession()
public static java.lang.String getPageId(javax.servlet.ServletRequest _req)
_req
- the request to look up the page id
public static java.lang.String getPageId(javax.servlet.http.HttpSession _sess)
_sess
- the session to look up the page id
public static void setPageId(javax.servlet.ServletRequest request, javax.servlet.http.HttpSession session, java.lang.String _idPage)
request
- the request related to the page idsession
- the session of the user_idPage
- the page idpublic static java.lang.String initPageId(javax.servlet.jsp.PageContext pageContext, java.lang.String pageName)
pageContext
- the page context of the pagepageName
- the name specified in the page in resourcesImport (null if none)
public static java.lang.String initPageId(javax.servlet.http.HttpServletRequest request, java.lang.String pageName)
request
- the http request which contains the request datapageName
- the name specified in the page in resourcesImport (null if none)
public static java.lang.String initPageId(javax.servlet.ServletRequest request, javax.servlet.http.HttpSession session, java.lang.String pageName)
request
- the servlet requestsession
- the session to init forpageName
- the name specified in the page in resourcesImport (null if none)
public ModelRegistry getModelRegistry()
public IModel getModel(java.lang.String id)
id
- the id of the model to get for this page
java.lang.IllegalArgumentException
- if no model exist with this idfor more APIs on this page's models
public void addModel(IModel model)
model
- the model to add to the registry of this pagepublic java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |