Skip to main content
Represents a reference to a saved Weave object. Generally, end users will not need to interact with this class directly. An ObjectRef contains the project ID, object ID, and digest that uniquely identify a saved object in Weave’s storage system.

Example

Constructor

new ObjectRef(projectId, objectId, digest): ObjectRef

Parameters

string
required
string
required
string
required

Returns

ObjectRef

Properties

digest

digest: string

objectId

objectId: string

projectId

projectId: string

Methods

get()

get(): Promise<any>

Returns

Promise<any>

ui_url()

ui_url(): string

Returns

string

uri()

uri(): string

Returns

string

fromUri()

static fromUri(uri): ObjectRef
Creates an ObjectRef from a Weave URI string.

Parameters

string
required
A Weave URI in the format: weave:///entity/project/object/name:digest

Returns

ObjectRef A new ObjectRef instance

Throws

Error if the URI format is invalid or not an object ref

Example