FluidFetchReader Class
Document storage service for the file driver.
Signature
export declare class FluidFetchReader extends ReadDocumentStorageServiceBase implements IDocumentStorageService
Extends: ReadDocumentStorageServiceBase
Implements: IDocumentStorageService
Constructors
Constructor | Description |
---|---|
(constructor)(path, versionName) | Constructs a new instance of the FluidFetchReader class |
Properties
Property | Type | Description |
---|---|---|
docTree | api.ISnapshotTree | null |
Methods
Method | Return Type | Description |
---|---|---|
getSnapshotTree(version) | Promise<api.ISnapshotTree | null> | Read the file and returns the snapshot tree. |
getVersions(versionId, count) | Promise<api.IVersion[]> | Gets the path of the snapshot tree to be read. |
readBlob(sha) | Promise<ArrayBufferLike> |
Constructor Details
(constructor)
Constructs a new instance of the FluidFetchReader
class
Signature
constructor(path: string, versionName?: string | undefined);
Parameters
Parameter | Modifiers | Type | Description |
---|---|---|---|
path | string | ||
versionName | optional | string | undefined |
Property Details
docTree
Signature
protected docTree: api.ISnapshotTree | null;
Type: api.ISnapshotTree | null
Method Details
getSnapshotTree
Read the file and returns the snapshot tree.
Signature
getSnapshotTree(version?: api.IVersion): Promise<api.ISnapshotTree | null>;
Parameters
Parameter | Modifiers | Type | Description |
---|---|---|---|
version | optional | api.IVersion | The version contains the path of the file which contains the snapshot tree. |
Returns
Return type: Promise<api.ISnapshotTree | null>
getVersions
Gets the path of the snapshot tree to be read.
Signature
getVersions(versionId: string | null, count: number): Promise<api.IVersion[]>;
Parameters
Parameter | Type | Description |
---|---|---|
versionId | string | null | version ID. |
count | number | Number of versions to be returned. |
Returns
Return type: Promise<api.IVersion[]>
readBlob
Signature
readBlob(sha: string): Promise<ArrayBufferLike>;
Parameters
Parameter | Type | Description |
---|---|---|
sha | string |
Returns
Return type: Promise<ArrayBufferLike>