org.scopemvc.view.servlet.jsp
Class JSPPage

java.lang.Object
  |
  +--org.scopemvc.view.servlet.Page
        |
        +--org.scopemvc.view.servlet.jsp.JSPPage
All Implemented Interfaces:
View

public class JSPPage
extends Page

A concrete Page. ***** Doesn't do the populateModel stuff yet

Version:
$Revision: 1.8 $ $Date: 2002/09/05 15:41:48 $
Author:
Steve Meyfroidt

Constructor Summary
JSPPage(java.lang.String inViewID, java.lang.String inJSPPath)
           
 
Method Summary
 java.lang.String getPath()
          Gets the path
protected  void init()
          Do it like this so that we can pick up application-specific ScopeConfig...
protected  void populateBoundModelProperty(java.lang.String inPropertyDescription, java.lang.String inValue)
          Use the property_description, property_value pair passed to set a property in the bound model to a new value.
 java.util.List populateModel(java.util.HashMap ioParameters)
           Interprets any form parameters like <PROPERTY_ID_PREFIX>SelectorDescription as [property_description, property_value] pairs
 
Methods inherited from class org.scopemvc.view.servlet.Page
equalsID, getBoundModel, getController, getID, getParent, issueControl, setBoundModel, setController, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JSPPage

public JSPPage(java.lang.String inViewID,
               java.lang.String inJSPPath)
Parameters:
inViewID - unique View ID for routing incoming Controls
inJSPPath - the path to the JSP this View uses
Method Detail

getPath

public final java.lang.String getPath()
Gets the path

Returns:
The path value

populateModel

public java.util.List populateModel(java.util.HashMap ioParameters)

Interprets any form parameters like <PROPERTY_ID_PREFIX>SelectorDescription as [property_description, property_value] pairs

Extracts the property_description from the form parameter key, then populates its model object using the String value. Any parameters treated this way are removed from the HashMap.

Overrides:
populateModel in class Page
Parameters:
ioParameters - form parameters to parse for [property_description, property_value] pairs, removing any processed pairs from the parameters before return
Returns:
PopulateModelFailedException that will be handled as a validation failure.

init

protected void init()
Do it like this so that we can pick up application-specific ScopeConfig... static initializers would happen before user got a chance to setup the custom config properties.


populateBoundModelProperty

protected void populateBoundModelProperty(java.lang.String inPropertyDescription,
                                          java.lang.String inValue)
                                   throws java.lang.Exception
Use the property_description, property_value pair passed to set a property in the bound model to a new value. Use StringConvertor if available to convert from String to the property's native datatype.

Parameters:
inPropertyDescription - TODO: Describe the Parameter
inValue - TODO: Describe the Parameter
Throws:
java.lang.Exception - on any failure


Copyright © 2000-2002 The Scope Team. All Rights Reserved.