main.cesium.DataSource.kt Maven / Gradle / Ivy
The newest version!
// Automatically generated - do not modify!
@file:JsModule("cesium")
package cesium
/**
* Defines the interface for data sources, which turn arbitrary data into a
* [EntityCollection] for generic consumption. This object is an interface
* for documentation purposes and is not intended to be instantiated directly.
* @see Online Documentation
*/
abstract external class DataSource {
/**
* Gets a human-readable name for this instance.
* @see Online Documentation
*/
abstract var name: String
/**
* Gets the preferred clock settings for this data source.
* @see Online Documentation
*/
abstract var clock: DataSourceClock
/**
* Gets the collection of [Entity] instances.
* @see Online Documentation
*/
abstract var entities: EntityCollection
/**
* Gets a value indicating if the data source is currently loading data.
* @see Online Documentation
*/
abstract var isLoading: Boolean
/**
* Gets an event that will be raised when the underlying data changes.
* @see Online Documentation
*/
abstract var changedEvent: Event
/**
* Gets an event that will be raised if an error is encountered during processing.
* @see Online Documentation
*/
abstract var errorEvent: Event
/**
* Gets an event that will be raised when the value of isLoading changes.
* @see Online Documentation
*/
abstract var loadingEvent: Event
/**
* Gets whether or not this data source should be displayed.
* @see Online Documentation
*/
abstract var show: Boolean
/**
* Gets or sets the clustering options for this data source. This object can be shared between multiple data sources.
* @see Online Documentation
*/
abstract var clustering: EntityCluster
/**
* 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.
* @param [time] The simulation time.
* @return True if this data source is ready to be displayed at the provided time, false otherwise.
* @see Online Documentation
*/
abstract fun update(time: JulianDate): Boolean
}