IonResource

external class IonResource(endpoint: ERROR CLASS: Symbol not found for JsAny, endpointResource: Resource)(source)

A Resource instance that encapsulates Cesium ion asset access. This object is normally not instantiated directly, use IonResource.fromAssetId.

Parameters

endpoint

The result of the Cesium ion asset endpoint service.

endpointResource

The resource used to retrieve the endpoint.

See also

Constructors

Link copied to clipboard
constructor(endpoint: ERROR CLASS: Symbol not found for JsAny, endpointResource: Resource)

Types

Link copied to clipboard
object Companion
Link copied to clipboard

Properties

Link copied to clipboard
val credits: ERROR CLASS: Symbol not found for ReadonlyArray<cesium/engine/Credit>

Gets the credits required for attribution of the asset.

Functions

Link copied to clipboard
fun clone(result: Resource? = definedExternally): Resource

Duplicates a Resource instance.

Link copied to clipboard
suspend fun fetchImage(options: IonResource.FetchImageOptions? = definedExternally): ERROR CLASS: Symbol not found for CanvasImageSource??

Asynchronously loads the given image resource. Returns a promise that will resolve to an ImageBitmap if preferImageBitmap is true and the browser supports createImageBitmap or otherwise an Image once loaded, or reject if the image failed to load.

Link copied to clipboard
fun fetchImageAsync(options: IonResource.FetchImageOptions? = definedExternally): ERROR CLASS: Symbol not found for Promise<ERROR CLASS: Symbol not found for CanvasImageSource>??