Skip to main content
Version: 3.x

Interface: ModelDataProvider

@cognite/reveal/extensions/datasource.ModelDataProvider

Provides data for 3D models.

Hierarchy

  • JsonFileProvider

  • BinaryFileProvider

    ModelDataProvider

Methods

getBinaryFile

getBinaryFile(baseUrl, fileName): Promise<ArrayBuffer>

Downloads a binary blob.

Parameters

NameTypeDescription
baseUrlstringBase URL of the model.
fileNamestringFilename of binary file.

Returns

Promise<ArrayBuffer>

Overrides

BinaryFileProvider.getBinaryFile

Defined in

packages/modeldata-api/src/types.ts:28


getJsonFile

getJsonFile(baseUrl, fileName): Promise<any>

Download and parse a JSON file and return the resulting struct.

Parameters

NameTypeDescription
baseUrlstringBase URL of the model.
fileNamestringFilename of JSON file.

Returns

Promise<any>

Overrides

JsonFileProvider.getJsonFile

Defined in

packages/modeldata-api/src/types.ts:22