InkFactory Class
Packages > @fluidframework/ink > InkFactory
Factory for Ink.
Signature:
/** @sealed */
export declare class InkFactory implements IChannelFactory
Implements: IChannelFactory
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
attributes | IChannelAttributes | Attributes of the channel. | |
Attributes | static |
IChannelAttributes | Attributes of the channel. |
type | string | String representing the type of the factory. | |
Type | static |
string | String representing the type of the factory. |
Methods
Method | Modifiers | Description |
---|---|---|
create(runtime, id) | Creates a local version of the channel. Calling attach on the object later will insert it into the object stream. | |
load(runtime, id, services, branchId, attributes) | 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. |
Properties
attributes
Attributes of the channel.
Signature:
get attributes(): IChannelAttributes;
Attributes
Attributes of the channel.
Signature:
static readonly Attributes: IChannelAttributes;
type
String representing the type of the factory.
Signature:
get type(): string;
Type
String representing the type of the factory.
Signature:
static Type: string;
Methods
create
Creates a local version of the channel. Calling attach on the object later will insert it into the object stream.
Signature:
create(runtime: IFluidDataStoreRuntime, id: string): ISharedObject;
Parameters
Parameter | Type | Description |
---|---|---|
runtime | IFluidDataStoreRuntime | The runtime the new object will be associated with |
id | string | The unique ID of the new object |
Returns:
The newly created object.
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, branchId: string, attributes: IChannelAttributes): Promise<ISharedObject>;
Parameters
Parameter | Type | Description |
---|---|---|
runtime | IFluidDataStoreRuntime | Data store runtime containing state/info/helper methods about the data store. |
id | string | ID of the channel. |
services | IChannelServices | Services to read objects at a given path using the delta connection. |
branchId | string | The branch ID. |
attributes | IChannelAttributes |
Returns:
Promise<ISharedObject>
The loaded object