ExternalDataSource

Class through which user can set its own sensors data (e.g. GPS positions)

Constructors

Link copied to clipboard
constructor(address: Long)

Inherited properties

Link copied to clipboard

Address of native referenced object. nullptr if not referencing any native allocated object. Note native allocation will happen only once.

Link copied to clipboard
val availableDataTypes: ArrayList<<Error class: unknown class>>

Available data types.

Link copied to clipboard

Data source type. It can be live or playback.

Link copied to clipboard

Origin of the data source

Link copied to clipboard

Playback If data source has no playback capabilities the interface return null

Functions

Link copied to clipboard
external fun pushData(data: SenseData)

Push data in external data source

Inherited functions

Link copied to clipboard
fun addListener(listener: DataSourceListener, types: ArrayList<Pair<<Error class: unknown class>, ParameterList?>>, critical: Boolean = true)
fun addListener(listener: DataSourceListener, type: <Error class: unknown class>, preferences: ParameterList? = null, critical: Boolean = true): Int

Adds a listener to a specific 'dataType'

Link copied to clipboard
external fun addSurfaceToCamera(previewSurface: <Error class: unknown class>): Pair<Int, Int>?

Attaches the surface to be rendered into directly by the camera.

Link copied to clipboard
fun finalize()

Overrides finalize that garbage collector will call when needed.

Link copied to clipboard
fun getDataTypeDescription(type: <Error class: unknown class>): String?
Link copied to clipboard
fun getLatestData(dataType: <Error class: unknown class>): SenseData?
Link copied to clipboard
fun getPreferences(type: <Error class: unknown class>): ParameterList?

Provides access to the current configuration specified to that data type.

Link copied to clipboard
fun isDataTypeAvailable(type: <Error class: unknown class>): Boolean

Test if a data type is provided by the data source.

Link copied to clipboard
fun isMockData(type: <Error class: unknown class>): Boolean

Check if mock data is enabled for the given type

Link copied to clipboard

True if keeps a reference to a C++ SDK object False if keeps a C++ SDK object

Link copied to clipboard
external fun isStopped(): Boolean

Checks if the source is stopped

Link copied to clipboard
operator fun not(): Boolean

Checks if this object is valid.

Link copied to clipboard
fun release()

Releases the native referenced value of this object if:

Link copied to clipboard
external fun removeCameraSurface(surfaceID: Int): Int

Detaches the surface with provided Id from the camera.

Link copied to clipboard
external fun removeListener(listener: DataSourceListener)
fun removeListener(listener: DataSourceListener, type: <Error class: unknown class>): Int

Removes the listener

Link copied to clipboard
fun setMockData(type: <Error class: unknown class>, data: SenseData): Int

Set mock data

Link copied to clipboard
fun setPreferences(type: <Error class: unknown class>, config: ParameterList?): Int

Updates the configuration for the specified dataType.

Link copied to clipboard
external fun start(): Int

Starts the source

Link copied to clipboard
external fun stop(): Int

Stops the source