Skip to main content

MockHandle Class

Mock implementation of IFluidHandle.

This API is provided for existing users, but is not recommended for new users.

To use, import via @fluidframework/test-runtime-utils/legacy.

For more information about our API support guarantees, see here.

Signature

export declare class MockHandle<T> extends FluidHandleBase<T>

Extends: FluidHandleBase<T>

Type Parameters

ParameterDescription
T

Constructors

ConstructorAlertsDescription
(constructor)(value, path, absolutePath)BetaConstructs a new instance of the MockHandle class

Properties

PropertyAlertsModifiersTypeDescription
absolutePathBetareadonlystring
isAttachedBetareadonlyboolean
pathBetareadonlystring
valueBetareadonlyT

Methods

MethodAlertsReturn TypeDescription
attachGraph()Betavoid
get()BetaPromise<T>

Constructor Details

(constructor)

Constructs a new instance of the MockHandle class

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

constructor(value: T, path?: string, absolutePath?: string);

Parameters

ParameterModifiersTypeDescription
valueT
pathoptionalstring
absolutePathoptionalstring

Property Details

absolutePath

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

readonly absolutePath: string;

Type: string

isAttached

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

get isAttached(): boolean;

Type: boolean

path

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

readonly path: string;

Type: string

value

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

protected readonly value: T;

Type: T

Method Details

attachGraph

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

attachGraph(): void;

get

This API is provided for existing users, but is not recommended for new users.

For more information about our API support guarantees, see here.

Signature

get(): Promise<T>;

Returns

Return type: Promise<T>