Community Map Builder 27 Apr 2008

Class Context

Object
   |
   +--Listener
         |
         +--ModelBase
               |
               +--Context

class Context
extends ModelBase

Defined in Context.js

Author: Cameron Shorter


Field Summary
 Object namespace
          
   
Fields inherited from class ModelBase
async, contentType, modelNode, id, title, debug, url, method, namespace, template, nodeSelectXpath, config, parentModel
   
Fields inherited from class Listener
listeners, values
 
Constructor Summary
Context (modelNode, parent)
            Stores a Web Map Context (WMC) document as defined by the Open Geospatial Consortium (http://www.opengeospatial.org/) and extensions the the WMC.
 
Method Summary
 void addLayer(objRef, layerNode)
           Method to add a Layer to the LayerList
 void addSLD(objRef,sldNode)
           Method to add a Sld tag to the StyleList
 void clearTimeExtent( objRef )
           clear the time extent created by initTimeExtent
 void deleteLayer(objRef, layerId)
           Method to remove a Layer from the LayerList
 Object getAllLayers()
           Method to get a list of all layers in the context doc TBD: merge this with above, passing queryable as an optional boolean param?
 Object getBoundingBox()
           Get the BoundingBox value from the Context document.
 Object getCurrentTimestamp( layerId )
           Returns the current timestamp value.
 Object getExtension()
           Returns the contents of the extension element
 Object getFeatureNode(featureName)
           Returns the Layer node with the specified name from the list of nodes selected by the nodeSelectXpath from the capabilities doc.
 Object getHidden(layerId)
           Get the layer's visiblity attribute value.
 Object getLayer(layerId)
           Method to get a layer with the specified name in the context doc
 Object getLayerIdByName(layerName)
           Method to get a layer id with the specified id/name in the context doc
 Object getMethod(feature)
           Get HTTP method for the specified feature
 Object getOpacity(layerId)
           Get the layer's opacity attribute value.
 Object getQueryableLayers()
           Method to get a list of queryable layers
 Object getServerUrl(requestName, method, feature)
           Returns the serverUrl for the layer passed in as the feature argument.
 Object getSRS()
           Get the Spatial Reference System from the context document.
 Object getVersion(feature)
           Returns the WMS version for the layer passed in as the feature argument
 Object getWindowHeight()
           Get the Window height.
 Object getWindowSize()
           Returns the width/height of the map window as an array
 Object getWindowWidth()
           Get the Window width.
 void initAoi(objRef)
           Set the aoi param and call the refresh listeners
 void initBbox(objRef)
           Set the BoundingBox element and call the refresh listeners
 Object initProj(objRef)
           Get the Projection object from the context document.
 void initTimeExtent( objRef )
           Parses a Dimension element from the Context document as a loadModel listener.
 void moveLayerDown(objRef, layerId)
           Method to move a Layer in the LayerList down
 void moveLayerUp(objRef, layerId)
           Method to move a Layer in the LayerList up
 void setBoundingBox(boundingBox)
           Set the BoundingBox element and call the refresh listeners
 Object setExtension(extensionNode)
           Adds a node to the Context document extension element.
 void setHidden(layerId, hidden)
           Change a Layer's visibility.
 void setOpacity(layerId, Opacity)
           Change a Layer's opacity
 void setSRS(srs)
           Set the Spatial Reference System for the context document.
 void setWindowHeight(height)
           Set the Window height.
 void setWindowSize(size)
           Set the Window width and height in one function call to avoid a resize event in between setting width and height, because that causes checkBbox to be triggered, which adjusts the bbox then when it should not yet be adjusted.
 void setWindowWidth(width)
           Set the Window width.
 
Methods inherited from class ModelBase
getProperty, getXpathValue, setXpathValue, loadModelDoc, setModel, finishLoading, newRequest, deleteTemplates, saveModel, createObject, loadObjects, parseConfig, refresh, init, clearModel
   
Methods inherited from class Listener
addListener, addFirstListener, removeListener, callListeners, setParam, getParam
 

Field Detail

namespace

Object namespace

Constructor Detail

Context

Context(modelNode, parent)

Method Detail

addLayer

void addLayer(objRef, layerNode)

addSLD

void addSLD(objRef,sldNode)

clearTimeExtent

void clearTimeExtent( objRef )

deleteLayer

void deleteLayer(objRef, layerId)

getAllLayers

Object getAllLayers()

getBoundingBox

Object getBoundingBox()

getCurrentTimestamp

Object getCurrentTimestamp( layerId )

getExtension

Object getExtension()

getFeatureNode

Object getFeatureNode(featureName)

getHidden

Object getHidden(layerId)

getLayer

Object getLayer(layerId)

getLayerIdByName

Object getLayerIdByName(layerName)

getMethod

Object getMethod(feature)

getOpacity

Object getOpacity(layerId)

getQueryableLayers

Object getQueryableLayers()

getServerUrl

Object getServerUrl(requestName, method, feature)

getSRS

Object getSRS()

getVersion

Object getVersion(feature)

getWindowHeight

Object getWindowHeight()

getWindowSize

Object getWindowSize()

getWindowWidth

Object getWindowWidth()

initAoi

void initAoi(objRef)

initBbox

void initBbox(objRef)

initProj

Object initProj(objRef)

initTimeExtent

void initTimeExtent( objRef )

moveLayerDown

void moveLayerDown(objRef, layerId)

moveLayerUp

void moveLayerUp(objRef, layerId)

setBoundingBox

void setBoundingBox(boundingBox)

setExtension

Object setExtension(extensionNode)

setHidden

void setHidden(layerId, hidden)

setOpacity

void setOpacity(layerId, Opacity)

setSRS

void setSRS(srs)

setWindowHeight

void setWindowHeight(height)

setWindowSize

void setWindowSize(size)

setWindowWidth

void setWindowWidth(width)

Community Map Builder 27 Apr 2008

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