Skip to main content
Version: v1

DataObjectFactory Class

DataObjectFactory is the IFluidDataStoreFactory for use with DataObjects. It facilitates DataObject's features (such as its shared directory) by ensuring relevant shared objects etc are available to the factory.

Signature​

export declare class DataObjectFactory<TObj extends DataObject<I>, I extends DataObjectTypes = DataObjectTypes> extends PureDataObjectFactory<TObj, I>

Extends: PureDataObjectFactory

Type Parameters​

ParameterConstraintDefaultDescription
TObjDataObject<I>DataObject (concrete type)
IDataObjectTypesDataObjectTypesThe input types for the DataObject

Constructors​

ConstructorDescription
(constructor)(type, ctor, sharedObjects, optionalProviders, registryEntries, runtimeFactory)Constructs a new instance of the DataObjectFactory class

Constructor Details​

(constructor)​

Constructs a new instance of the DataObjectFactory class

Signature​

constructor(type: string, ctor: new (props: IDataObjectProps<I>) => TObj, sharedObjects: readonly IChannelFactory[] | undefined, optionalProviders: FluidObjectSymbolProvider<I["OptionalProviders"]>, registryEntries?: NamedFluidDataStoreRegistryEntries, runtimeFactory?: typeof FluidDataStoreRuntime);

Parameters​

ParameterModifiersTypeDescription
typestring
ctornew (props: IDataObjectProps<I>) => TObj
sharedObjectsreadonly IChannelFactory[] | undefined
optionalProvidersFluidObjectSymbolProvider<I["OptionalProviders"]>
registryEntriesoptionalNamedFluidDataStoreRegistryEntries
runtimeFactoryoptionaltypeof FluidDataStoreRuntime