Community Map Builder 27 Apr 2008

Class ModelBase

Object
   |
   +--Listener
         |
         +--ModelBase
Direct Known Subclasses:
GeoRSS, FeatureCollection, Config, Model, Transaction, StyledLayerDescriptor, WmsCapabilities, Context, OwsContext, WpsCapabilities, Logger, WpsDescribeProcess, WfsCapabilities

class ModelBase
extends Listener

Defined in ModelBase.js

Author: Cameron Shorter


Field Summary
 Object async
          
 Object config
          Widgets can place configurations in a model.
 Object contentType
          
 Object debug
          
 Object id
          
 Object method
          
 Object modelNode
          
 Object namespace
          
 Object nodeSelectXpath
          
 Object parentModel
          
 Object template
          
 Object title
          
 Object url
          
   
Fields inherited from class Listener
listeners, values
 
Constructor Summary
ModelBase (modelNode, parentModel)
            Base Model class to be inherited by all Model objects and provdes methods and properties common to all models.
 
Method Summary
 void clearModel(objRef)
           Listener registered with the parent model to remove the doc and url of child models whenever the parent is reloaded.
 Object createObject(configNode)
           Creates all mapbuilder JavaScript objects based on the Object nodes defined in the configuration file.
 void deleteTemplates()
           deletes all template models and clears their widgets
 void finishLoading()
           Common steps to be carried out after all manner of model loading Called to set the namespace for XPath selections and call the loadModel listeners.
 Object getProperty(property, defaultValue)
           Convenient access to Mapbuilder.getProperty
 Object getXpathValue(objRef,xpath)
           Get the value of a node as selected by an XPath expression.1
 void init(objRef)
           Listener registered with the parent model to call init listeners when the parent model is init'ed
 void loadModelDoc(objRef)
           Load a Model's document.
 void loadObjects(objectXpath)
           Creates all the mapbuilder objects from the config file as selected by the XPath value passed in.
 void newRequest(objRef, httpPayload)
           Load XML for a model from an httpPayload object.
 void parseConfig(objRef)
           Initialization of all javascript model, widget and tool objects for this model.
 void refresh(objRef)
           Listener registered with the parent model to call refresh listeners when the model document is loaded
 void saveModel(objRef)
           save the model by posting it to the serializeUrl, which is defined as a property of config.
 void setModel(objRef,newModel)
           Set the model's XML document using an XML object as a parameter.
 Object setXpathValue(objRef,xpath,value,refresh)
           Update the value of a node within this model's XML document.
 
Methods inherited from class Listener
addListener, addFirstListener, removeListener, callListeners, setParam, getParam
 

Field Detail

async

Object async

config

Object config

contentType

Object contentType

debug

Object debug

id

Object id

method

Object method

modelNode

Object modelNode

namespace

Object namespace

nodeSelectXpath

Object nodeSelectXpath

parentModel

Object parentModel

template

Object template

title

Object title

url

Object url

Constructor Detail

ModelBase

ModelBase(modelNode, parentModel)

Method Detail

clearModel

void clearModel(objRef)

createObject

Object createObject(configNode)

deleteTemplates

void deleteTemplates()

finishLoading

void finishLoading()

getProperty

Object getProperty(property, defaultValue)

getXpathValue

Object getXpathValue(objRef,xpath)

init

void init(objRef)

loadModelDoc

void loadModelDoc(objRef)

loadObjects

void loadObjects(objectXpath)

newRequest

void newRequest(objRef, httpPayload)

parseConfig

void parseConfig(objRef)

refresh

void refresh(objRef)

saveModel

void saveModel(objRef)

setModel

void setModel(objRef,newModel)

setXpathValue

Object setXpathValue(objRef,xpath,value,refresh)

Community Map Builder 27 Apr 2008

Documentation generated by JSDoc on Sun Apr 27 20:30:54 2008