@ttsc/graph 0.21.0 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/model/loadGraph.d.ts +15 -0
- package/lib/model/loadGraph.js +580 -574
- package/lib/model/loadGraph.js.map +1 -1
- package/lib/reduce.js +27 -15
- package/lib/reduce.js.map +1 -1
- package/lib/view.js +26 -3
- package/lib/view.js.map +1 -1
- package/package.json +3 -3
- package/src/model/loadGraph.ts +11 -2
- package/src/reduce.ts +37 -18
- package/src/view.ts +29 -5
package/lib/model/loadGraph.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ITtscGraphDump } from "../structures/ITtscGraphDump";
|
|
1
2
|
import { TtscGraphMemory } from "./TtscGraphMemory";
|
|
2
3
|
/**
|
|
3
4
|
* The dump schema version this client reads.
|
|
@@ -35,3 +36,17 @@ export declare function loadGraph(options?: {
|
|
|
35
36
|
*/
|
|
36
37
|
binary?: string;
|
|
37
38
|
}): TtscGraphMemory;
|
|
39
|
+
/**
|
|
40
|
+
* Parse and validate `ttscgraph dump` output. typia asserts the full
|
|
41
|
+
* {@link ITtscGraphDump} shape so a malformed or stale dump fails loudly here
|
|
42
|
+
* rather than producing wrong answers downstream, and the schema version is
|
|
43
|
+
* checked so an incompatible producer is refused.
|
|
44
|
+
*
|
|
45
|
+
* The version is read before the shape: a dump from another schema is entitled
|
|
46
|
+
* to another shape, so asserting first would report the mismatch as a field
|
|
47
|
+
* complaint about a contract that producer never agreed to. A dump also
|
|
48
|
+
* outlives the process that wrote it — this is the one-shot path, and the JSON
|
|
49
|
+
* on disk may be from any build — so the version is the first question to ask
|
|
50
|
+
* of it.
|
|
51
|
+
*/
|
|
52
|
+
export declare function parseDump(json: string): ITtscGraphDump;
|