@fluidframework/protocol-definitions
Advanced tools
Comparing version 0.1018.0-13061 to 0.1018.0-13333
@@ -47,8 +47,18 @@ /*! | ||
*/ | ||
export interface ITreeEntry { | ||
export declare type ITreeEntry = { | ||
path: string; | ||
type: string; | ||
value: IBlob | IAttachment | ITree | string; | ||
mode: FileMode; | ||
} | ||
} & ({ | ||
type: TreeEntry.Blob; | ||
value: IBlob; | ||
} | { | ||
type: TreeEntry.Commit; | ||
value: string; | ||
} | { | ||
type: TreeEntry.Tree; | ||
value: ITree; | ||
} | { | ||
type: TreeEntry.Attachment; | ||
value: IAttachment; | ||
}); | ||
/** | ||
@@ -65,6 +75,6 @@ * Type of entries that can be stored in a tree | ||
entries: ITreeEntry[]; | ||
id: string | null; | ||
id?: string; | ||
} | ||
export interface ISnapshotTree { | ||
id: string | null; | ||
id?: string; | ||
blobs: { | ||
@@ -80,2 +90,8 @@ [path: string]: string; | ||
} | ||
export interface ISnapshotTreeEx extends ISnapshotTree { | ||
id: string; | ||
trees: { | ||
[path: string]: ISnapshotTreeEx; | ||
}; | ||
} | ||
/** | ||
@@ -82,0 +98,0 @@ * Represents a version of the snapshot of a data store |
@@ -47,8 +47,18 @@ /*! | ||
*/ | ||
export interface ITreeEntry { | ||
export declare type ITreeEntry = { | ||
path: string; | ||
type: string; | ||
value: IBlob | IAttachment | ITree | string; | ||
mode: FileMode; | ||
} | ||
} & ({ | ||
type: TreeEntry.Blob; | ||
value: IBlob; | ||
} | { | ||
type: TreeEntry.Commit; | ||
value: string; | ||
} | { | ||
type: TreeEntry.Tree; | ||
value: ITree; | ||
} | { | ||
type: TreeEntry.Attachment; | ||
value: IAttachment; | ||
}); | ||
/** | ||
@@ -65,6 +75,6 @@ * Type of entries that can be stored in a tree | ||
entries: ITreeEntry[]; | ||
id: string | null; | ||
id?: string; | ||
} | ||
export interface ISnapshotTree { | ||
id: string | null; | ||
id?: string; | ||
blobs: { | ||
@@ -80,2 +90,8 @@ [path: string]: string; | ||
} | ||
export interface ISnapshotTreeEx extends ISnapshotTree { | ||
id: string; | ||
trees: { | ||
[path: string]: ISnapshotTreeEx; | ||
}; | ||
} | ||
/** | ||
@@ -82,0 +98,0 @@ * Represents a version of the snapshot of a data store |
{ | ||
"name": "@fluidframework/protocol-definitions", | ||
"version": "0.1018.0-13061", | ||
"version": "0.1018.0-13333", | ||
"description": "Fluid protocol definitions", | ||
@@ -5,0 +5,0 @@ "homepage": "https://fluidframework.com", |
@@ -59,16 +59,22 @@ /*! | ||
*/ | ||
export interface ITreeEntry { | ||
export type ITreeEntry = { | ||
// Path to the object | ||
path: string; | ||
// One of the below enum string values | ||
type: string; | ||
// The value of the entry - either a tree or a blob | ||
value: IBlob | IAttachment | ITree | string; | ||
// The file mode; one of 100644 for file (blob), 100755 for executable (blob), 040000 for subdirectory (tree), | ||
// 160000 for submodule (commit), or 120000 for a blob that specifies the path of a symlink | ||
mode: FileMode; | ||
} | ||
} & ( | ||
{ | ||
type: TreeEntry.Blob; | ||
value: IBlob; | ||
} | { | ||
type: TreeEntry.Commit; | ||
value: string; | ||
} | { | ||
type: TreeEntry.Tree; | ||
value: ITree; | ||
} | { | ||
type: TreeEntry.Attachment; | ||
value: IAttachment; | ||
}); | ||
@@ -90,8 +96,9 @@ /** | ||
// it is known that the ITree has already been created and stored | ||
id: string | null; | ||
id?: string; | ||
} | ||
export interface ISnapshotTree { | ||
id: string | null; | ||
id? : string; | ||
blobs: { [path: string]: string }; | ||
// TODO: Commits should be removed from here to ISnapshotTreeEx once ODSP snapshots move away from commits | ||
commits: { [path: string]: string }; | ||
@@ -101,2 +108,7 @@ trees: { [path: string]: ISnapshotTree }; | ||
export interface ISnapshotTreeEx extends ISnapshotTree { | ||
id: string; | ||
trees: { [path: string]: ISnapshotTreeEx }; | ||
} | ||
/** | ||
@@ -103,0 +115,0 @@ * Represents a version of the snapshot of a data store |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
145900
2357