SharedObjectCore Class
Base class from which all shared objects derive.
To use, import via @fluidframework/shared-object-base/legacy
.
For more information about our API support guarantees, see here.
Signature
export declare abstract class SharedObjectCore<TEvent extends ISharedObjectEvents = ISharedObjectEvents> extends EventEmitterWithErrorHandling<TEvent> implements ISharedObject<TEvent>
Extends: EventEmitterWithErrorHandling<TEvent>
Implements: ISharedObject<TEvent>
Type Parameters
Parameter | Constraint | Default | Description |
---|---|---|---|
TEvent | ISharedObjectEvents | ISharedObjectEvents |
Remarks
This class implements common behaviors that implementations of ISharedObject may want to reuse. Even more such behaviors are implemented in the SharedObject class.
Constructors
Constructor | Alerts | Description |
---|---|---|
(constructor)(id, runtime, attributes) | Alpha |
Constructs a new instance of the SharedObjectCore class |
Properties
Property | Alerts | Modifiers | Type | Description |
---|---|---|---|---|
attributes | Alpha |
readonly |
IChannelAttributes | The attributes of the Shared Object. |
connected | Alpha |
readonly |
boolean | Gets the connection state |
deltaManager | Alpha |
readonly |
IDeltaManager<ISequencedDocumentMessage, IDocumentMessage> | Accessor for this.runtime 's deltaManager as a @fluidframework/container-definitions/internal#IDeltaManager |
handle | Alpha |
readonly |
IFluidHandleInternal | The handle referring to this SharedObject |
id | Alpha |
string | The ID of the shared object. | |
IFluidLoadable | Alpha |
readonly |
this | |
logger | Alpha |
readonly |
ITelemetryLoggerExt | Telemetry logger for the shared object |
runtime | Alpha |
IFluidDataStoreRuntime | The runtime instance that contains the Shared Object. | |
serializer | Alpha |
readonly |
IFluidSerializer | The serializer to serialize / parse handles. |
Constructor Details
(constructor)
Constructs a new instance of the SharedObjectCore
class
For more information about our API support guarantees, see here.
Signature
constructor(
id: string,
runtime: IFluidDataStoreRuntime,
attributes: IChannelAttributes);
Parameters
Parameter | Type | Description |
---|---|---|
id | string | |
runtime | IFluidDataStoreRuntime | |
attributes | IChannelAttributes |
Property Details
attributes
The attributes of the Shared Object.
For more information about our API support guarantees, see here.
Signature
readonly attributes: IChannelAttributes;
Type: IChannelAttributes
connected
Gets the connection state
For more information about our API support guarantees, see here.
Signature
get connected(): boolean;
Type: boolean
deltaManager
Accessor for this.runtime
's deltaManager as a @fluidframework/container-definitions/internal#IDeltaManager
For more information about our API support guarantees, see here.
Signature
protected get deltaManager(): IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;
Type: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>
handle
The handle referring to this SharedObject
For more information about our API support guarantees, see here.
Signature
readonly handle: IFluidHandleInternal;
Type: IFluidHandleInternal
id
The ID of the shared object.
For more information about our API support guarantees, see here.
Signature
id: string;
Type: string
IFluidLoadable
For more information about our API support guarantees, see here.
Signature
get IFluidLoadable(): this;
Type: this
logger
Telemetry logger for the shared object
For more information about our API support guarantees, see here.
Signature
protected readonly logger: ITelemetryLoggerExt;
Type: ITelemetryLoggerExt
runtime
The runtime instance that contains the Shared Object.
For more information about our API support guarantees, see here.
Signature
protected runtime: IFluidDataStoreRuntime;
Type: IFluidDataStoreRuntime
serializer
The serializer to serialize / parse handles.
For more information about our API support guarantees, see here.
Signature
protected abstract get serializer(): IFluidSerializer;
Type: IFluidSerializer