Skip to main content
Version: v1

SharedStringFactory Class

Signature​

export declare class SharedStringFactory implements IChannelFactory

Implements: IChannelFactory

Static Properties​

PropertyTypeDescription
AttributesIChannelAttributes
Typestring

Static Methods​

MethodReturn TypeDescription
segmentFromSpec(spec)SharedStringSegment

Properties​

PropertyTypeDescription
attributesIChannelAttributes
typestring

Methods​

MethodReturn TypeDescription
create(document, id)SharedString
load(runtime, id, services, attributes)Promise<SharedString>Loads the given channel. This call is only ever invoked internally as the only thing that is ever directly loaded is the document itself. Load will then only be called on documents that were created and added to a channel.

Property Details​

attributes​

Signature​

get attributes(): IChannelAttributes;

Type: IChannelAttributes

Attributes​

Signature​

static readonly Attributes: IChannelAttributes;

Type: IChannelAttributes

type​

Signature​

get type(): string;

Type: string

Type​

Signature​

static Type: string;

Type: string

Method Details​

create​

Signature​

create(document: IFluidDataStoreRuntime, id: string): SharedString;

Parameters​

ParameterTypeDescription
documentIFluidDataStoreRuntime
idstring

Returns​

Return type: SharedString

load​

Loads the given channel. This call is only ever invoked internally as the only thing that is ever directly loaded is the document itself. Load will then only be called on documents that were created and added to a channel.

Signature​

load(runtime: IFluidDataStoreRuntime, id: string, services: IChannelServices, attributes: IChannelAttributes): Promise<SharedString>;

Parameters​

ParameterTypeDescription
runtimeIFluidDataStoreRuntimeData store runtime containing state/info/helper methods about the data store.
idstringID of the channel.
servicesIChannelServicesServices to read objects at a given path using the delta connection.
attributesIChannelAttributes

Returns​

The loaded object

Return type: Promise<SharedString>

segmentFromSpec​

Signature​

static segmentFromSpec(spec: any): SharedStringSegment;

Parameters​

ParameterTypeDescription
specany

Returns​

Return type: SharedStringSegment