Class MVCScalarView
Object
|
+--GrvObject
|
+--MVCView
|
+--MVCScalarView
-
Direct Known Subclasses:
-
MVCPadScalarView
- class
MVCScalarView
- extends MVCView
This class produces a view of the specified
MVCScalarModel. It accepts an optional formatter
function specification that will transform the raw value
of the model into a desired format. This formatter
function should accept one parameter (the value) and
return a formatted string version of that value.
Version: 2.0
Author: Bruce Wallace (PolyGlotInc.com)
See:
Defined in grvMVC.js
|
Method Summary |
String
|
buildHTMLstr( )
return an HTML string of the basic structure for this view.
|
String
|
formatted(x)
return the formatted version of the given value using our formatter
function (where the raw value is returned if no formatter is registered)
|
String
|
getValueStr( )
return the current value of our model formatted with our formatter
|
void
|
konstructor( <MVCScalarModel> xModel, <Function> optFormatFunction, <String> optName )
|
void
|
paintHTML( )
update/modify attributes of basic existing HTML for THIS view
|
void
|
setDisplay(x)
set the value of our display "widget"
|
void
|
updateView( )
update the display with the current model value
|
| Methods inherited from class MVCView |
mustRebuild, mustRepaint, currentContext, watchModel, setViewID, innerID, getWidgetID, getWidget, getHook, buildHTML, updateContext, contextChanged, disable, enable, setVisible, setSubViewsVisible, isVisible, redraw, draw, rebuildAny, build, buildsubviews, paint, setParentView, clearSubViews, addSubView, getSubView, delSubView, embedView, embedHTML, embedAttr, block, unblock
|
MVCScalarView
MVCScalarView()
Version: 2.0
Author: Bruce Wallace (PolyGlotInc.com)
See:
buildHTMLstr
String buildHTMLstr( )
return an HTML string of the basic structure for this view.
As a side effect, build/update subview list for this view.
As a side effect, invoke this method on each nested subview.
Returns:
HTML (suitable for assigning to innerHTML)
formatted
String formatted(x)
return the formatted version of the given value using our formatter
function (where the raw value is returned if no formatter is registered)
getValueStr
String getValueStr( )
return the current value of our model formatted with our formatter
konstructor
void konstructor( <MVCScalarModel> xModel, <Function> optFormatFunction, <String> optName )
Parameters:
xModel - the data model to view
optFormatFunction - optional formatter function
optName - optional name of this instance
paintHTML
void paintHTML( )
update/modify attributes of basic existing HTML for THIS view
setDisplay
void setDisplay(x)
set the value of our display "widget"
updateView
void updateView( )
update the display with the current model value
Documentation generated by
JSDoc on Sun Feb 11 13:28:59 2007