Packages > @fluidframework/map
@fluidframework/map Package
The map
library provides interfaces and implementing classes for map-like distributed data structures.
Remarks
The following distributed data structures are defined in this library:
Interfaces
Interface | Alerts | Description |
---|---|---|
ICreateInfo |
ALPHA
|
Create info for the subdirectory. |
IDirectory |
ALPHA
|
Interface describing actions on a directory. |
IDirectoryClearOperation |
ALPHA
|
Operation indicating the directory should be cleared. |
IDirectoryCreateSubDirectoryOperation |
ALPHA
|
Operation indicating a subdirectory should be created. |
IDirectoryDataObject |
ALPHA
|
Defines the in-memory object structure to be used for the conversion to/from serialized. |
IDirectoryDeleteOperation |
ALPHA
|
Operation indicating a key should be deleted from the directory. |
IDirectoryDeleteSubDirectoryOperation |
ALPHA
|
Operation indicating a subdirectory should be deleted. |
IDirectoryEvents |
ALPHA
|
Events emitted in response to changes to the directory data. |
IDirectorySetOperation |
ALPHA
|
Operation indicating a value should be set for a key. |
IDirectoryValueChanged |
ALPHA
|
Type of "valueChanged" event parameter for ISharedDirectory. |
ILocalValue |
ALPHA
|
A local value to be stored in a container type Distributed Data Store (DDS). |
ISerializableValue |
ALPHA , DEPRECATED
|
The _ready-for-serialization_ format of values contained in DDS contents. This allows us to use type to understand whether they're storing a Plain JavaScript object, a SharedObject, or a value type. |
ISerializedValue |
ALPHA
|
Serialized ISerializableValue counterpart. |
ISharedDirectory |
ALPHA
|
Provides a hierarchical organization of map-like data structures as SubDirectories. The values stored within can be accessed like a map, and the hierarchy can be navigated using path syntax. SubDirectories can be retrieved for use as working directories. |
ISharedDirectoryEvents |
ALPHA
|
Events emitted in response to changes to the directory data. |
ISharedMap |
ALPHA
|
The SharedMap distributed data structure can be used to store key-value pairs. It provides the same API for setting and retrieving values that JavaScript developers are accustomed to with the Map built-in object. However, the keys of a SharedMap must be strings, and the values must either be a JSON-serializable object or a @fluidframework/datastore#FluidObjectHandle. For more information, including example usages, see https://fluidframework.com/docs/data-structures/map/. |
ISharedMapEvents |
ALPHA
|
Events emitted in response to changes to the map data. |
IValueChanged |
ALPHA
|
Type of "valueChanged" event parameter. |
Classes
Class | Alerts | Modifiers | Description |
---|---|---|---|
DirectoryFactory |
ALPHA
|
sealed
|
IChannelFactory for SharedDirectory.
|
LocalValueMaker |
ALPHA
|
Enables a container type DDS to produce and store local values with minimal awareness of how those objects are stored, serialized, and deserialized. | |
MapFactory |
ALPHA
|
sealed
|
IChannelFactory for SharedMap.
|
SharedDirectory |
ALPHA
|
sealed
|
Provides a hierarchical organization of map-like data structures as SubDirectories. The values stored within can be accessed like a map, and the hierarchy can be navigated using path syntax. SubDirectories can be retrieved for use as working directories. |
SharedMap |
ALPHA
|
The SharedMap distributed data structure can be used to store key-value pairs. It provides the same API for setting and retrieving values that JavaScript developers are accustomed to with the Map built-in object. However, the keys of a SharedMap must be strings, and the values must either be a JSON-serializable object or a @fluidframework/datastore#FluidObjectHandle. For more information, including example usages, see https://fluidframework.com/docs/data-structures/map/. |
Types
TypeAlias | Alerts | Description |
---|---|---|
IDirectoryKeyOperation |
ALPHA
|
An operation on a specific key within a directory. |
IDirectoryOperation |
ALPHA
|
Any operation on a directory. |
IDirectoryStorageOperation |
ALPHA
|
An operation on one or more of the keys within a directory. |
IDirectorySubDirectoryOperation |
ALPHA
|
An operation on the subdirectories within a directory. |
Type Details
IDirectoryKeyOperation (ALPHA)
An operation on a specific key within a directory.
WARNING: This API is provided as an alpha preview and may change without notice. Use at your own risk.
Signature
export type IDirectoryKeyOperation = IDirectorySetOperation | IDirectoryDeleteOperation;
IDirectoryOperation (ALPHA)
Any operation on a directory.
WARNING: This API is provided as an alpha preview and may change without notice. Use at your own risk.
Signature
export type IDirectoryOperation = IDirectoryStorageOperation | IDirectorySubDirectoryOperation;
IDirectoryStorageOperation (ALPHA)
An operation on one or more of the keys within a directory.
WARNING: This API is provided as an alpha preview and may change without notice. Use at your own risk.
Signature
export type IDirectoryStorageOperation = IDirectoryKeyOperation | IDirectoryClearOperation;
IDirectorySubDirectoryOperation (ALPHA)
An operation on the subdirectories within a directory.
WARNING: This API is provided as an alpha preview and may change without notice. Use at your own risk.
Signature
export type IDirectorySubDirectoryOperation = IDirectoryCreateSubDirectoryOperation | IDirectoryDeleteSubDirectoryOperation;