Class: GeoPointsCesiumConnector

GeoPointsCesiumConnector()

This is the base model for other connectors that create geometry in Cesium based on points in a GeoPoints collection.

Constructor

new GeoPointsCesiumConnector()

Since:
  • 2.27.0
Source:

Extends

  • Backbone.Model

Members

type :string

The type of Backbone.Model this is.
Type:
  • string
Default Value:
  • "GeoPointsCesiumConnector"
Source:

Methods

connect()

Listen for changes to the Points collection and update the CesiumVectorData model with point entities.
Source:

defaults() → {Object}

Extends the default Backbone.Model.defaults() function to specify default attributes for the GeoPointsCesiumConnector model.
Properties:
Name Type Description
geoPoints GeoPoints The points collection to visualize
layer CesiumVectorData The CesiumVectorData model to use to visualize the points. This must be a CesiumVectorData model.
isConnected Boolean Whether the layer is currently being updated with changes to the points collection.
Source:
Returns:
The default attributes
Type
Object

disconnect()

Stop listening for changes to the Points collection.
Source:

handleCollectionChange(eventName, collection, options)

Handle add, remove, merge, and reset events from the points collection
Parameters:
Name Type Description
eventName "update" | "reset" The name of the event
collection GeoPoints The points collection
options Object Options for the event, as passed by Backbone
Source:

initialize(attrs)

Initialize the model.
Parameters:
Name Type Attributes Description
attrs Object The attributes for this model.
attributes.geoPoints GeoPoints | Array <optional>
The GeoPoints collection to use for this connector or an array of JSON attributes to create a new GeoPoints collection. If not provided, a new empty GeoPoints collection will be created.
attributes.layer CesiumVectorData | Object <optional>
The CesiumVectorData CesiumVectorData model to use for this connector or a JSON object with options to create a model. If not provided, a new layer will be created.
Source:

setGeoPoints(pointsopt) → {GeoPoints}

Set or create and set the GeoPoints collection for this connector.
Parameters:
Name Type Attributes Description
points GeoPoints | Object <optional>
The GeoPoints collection to use for this connector or an array of JSON attributes to create points.
Source:
Returns:
The GeoPoints collection for this connector.
Type
GeoPoints

setLayer(layeropt) → {CesiumVectorData}

Set or create and set the CesiumVectorData model for this connector.
Parameters:
Name Type Attributes Description
layer CesiumVectorData | Object <optional>
The CesiumVectorData model to use for this connector or a JSON object with options to create a new CesiumVectorData model. If not provided, a new CesiumVectorData model will be created.
Source:
Returns:
The CesiumVectorData model for this connector.
Type
CesiumVectorData