File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,16 @@ import {first, next} from 'sonic-forest/lib/util';
77import type { Printable } from '../../util/print/types' ;
88import type { JsonNode } from '../nodes/types' ;
99
10+ /**
11+ * The `Log` represents a history of patches applied to a JSON CRDT model. It
12+ * consists of: (1) a starting {@link Model} instance, (2) a list of {@link Patch} instances,
13+ * that can be applied to the starting model to reach the current state of the
14+ * document, and (3) the current state of the document, the `end` {@link Model}.
15+ *
16+ * The log can be used to replay the history of patches to any point in time,
17+ * from the "start" to the "end" of the log, and return the resulting {@link Model}
18+ * state.
19+ */
1020export class Log < N extends JsonNode = JsonNode < any > > implements Printable {
1121 /**
1222 * Creates a `PatchLog` instance from a newly JSON CRDT model. Checks if
You can’t perform that action at this time.
0 commit comments