|
|||||||||
| Home >> All >> org >> scopemvc >> view >> [ servlet overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.scopemvc.view.servlet
Class Page

java.lang.Objectorg.scopemvc.view.servlet.Page
- All Implemented Interfaces:
- org.scopemvc.core.View
- public abstract class Page
- extends java.lang.Object
- implements org.scopemvc.core.View
- extends java.lang.Object
Base class for views used by servlet implementation.
Pages in a browser do not communicate with the web server, so this class does not implement ModelChangeListener. Model objects in a web application shouldn't bother to implement ModelChangeEventSource unless change notification is used for some purpose other than updating Views.
In a servlet application, a Controller must use a ServletView that contains all possible Pages that the Controller can show.
Pages must be created with unique View IDs to allow incoming requests to be linked to the correct parent View instance in ScopeServlet. eg
http://localhost/scope/servlet/Test?view=TestView&action=TestControlcauses the View with ID "TestView" to issue a Control whose ID is "TestControl".
The concrete implementation will need to support the appropriate ViewContext: for example a JSPPage is tailored for use by the JSPContext whereas a ServletXSLPage offers a different API to the XSLServletContext.
- Version:
- $Revision: 1.7 $ $Date: 2002/01/26 09:46:20 $
| Field Summary | |
private java.lang.String |
id
Unique ID. |
private static org.apache.commons.logging.Log |
LOG
|
private ServletView |
parent
ServletView that contains this Page. |
| Constructor Summary | |
protected |
Page(java.lang.String inViewID)
Create with a unique ID. |
| Method Summary | |
boolean |
equalsID(java.lang.String inID)
|
java.lang.Object |
getBoundModel()
|
org.scopemvc.core.Controller |
getController()
|
java.lang.String |
getID()
|
ServletView |
getParent()
|
void |
issueControl(org.scopemvc.core.Control inControl)
Issue Control via the parent ServletView. |
java.util.List |
populateModel(java.util.HashMap inParameters)
Called from ScopeServlet.doPost. |
void |
setBoundModel(java.lang.Object inModel)
Parent ServletView is bound to a model, not each Page. |
void |
setController(org.scopemvc.core.Controller inController)
Parent ServletView has a Controller, not each Page. |
void |
setParent(ServletView inServletView)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
LOG
private static final org.apache.commons.logging.Log LOG
id
private java.lang.String id
- Unique ID.
parent
private ServletView parent
- ServletView that contains this Page.
| Constructor Detail |
Page
protected Page(java.lang.String inViewID)
- Create with a unique ID.
| Method Detail |
getID
public final java.lang.String getID()
setParent
public final void setParent(ServletView inServletView)
getParent
public final ServletView getParent()
equalsID
public final boolean equalsID(java.lang.String inID)
getBoundModel
public final java.lang.Object getBoundModel()
- Specified by:
getBoundModelin interfaceorg.scopemvc.core.View
setBoundModel
public final void setBoundModel(java.lang.Object inModel)
- Parent ServletView is bound to a model, not each Page.
- Specified by:
setBoundModelin interfaceorg.scopemvc.core.View
setController
public final void setController(org.scopemvc.core.Controller inController)
- Parent ServletView has a Controller, not each Page.
- Specified by:
setControllerin interfaceorg.scopemvc.core.View
getController
public final org.scopemvc.core.Controller getController()
- Specified by:
getControllerin interfaceorg.scopemvc.core.View
issueControl
public void issueControl(org.scopemvc.core.Control inControl)
- Issue Control via the parent ServletView.
- Specified by:
issueControlin interfaceorg.scopemvc.core.View
populateModel
public java.util.List populateModel(java.util.HashMap inParameters)
Called from ScopeServlet.doPost.
Implementing this method is optional -- Pages don't have to support population of their model. The default implementation here does nothing.
|
|||||||||
| Home >> All >> org >> scopemvc >> view >> [ servlet overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.scopemvc.view.servlet.Page