CustomDataSource

external class CustomDataSource(var name: String = definedExternally)(source)

A DataSource implementation which can be used to manually manage a group of entities.

const dataSource = new CustomDataSource('myData');

const entity = dataSource.entities.add({
position : Cartesian3.fromDegrees(1, 2, 0),
billboard : {
image : 'image.png'
}
});

viewer.dataSources.add(dataSource);

See also

Constructors

Link copied to clipboard
constructor(name: String = definedExternally)

Properties

Link copied to clipboard

Gets an event that will be raised when the underlying data changes.

Link copied to clipboard

Gets or sets the clock for this instance.

Link copied to clipboard

Gets or sets the clustering options for this data source. This object can be shared between multiple data sources.

Link copied to clipboard

Gets the collection of Entity instances.

Link copied to clipboard

Gets an event that will be raised if an error is encountered during processing.

Link copied to clipboard

Gets or sets whether the data source is currently loading data.

Link copied to clipboard

Gets an event that will be raised when the data source either starts or stops loading.

Link copied to clipboard

A human-readable name for this instance.

Link copied to clipboard

Gets whether or not this data source should be displayed.

Functions

Link copied to clipboard

Updates the data source to the provided time. This function is optional and is not required to be implemented. It is provided for data sources which retrieve data based on the current animation time or scene state. If implemented, update will be called by DataSourceDisplay once a frame.