MCPcopy Create free account
hub / github.com/cyclejs/cyclejs / getId

Method getId

devtool/src/graphSerializer.ts:62–71  ·  view source on GitHub ↗
(thing: Object)

Source from the content-addressed store, hash-verified

60 }
61
62 public getId(thing: Object): string {
63 if (!this.map.has(thing)) {
64 const id = this.mutableIncrementingId;
65 this.map.set(thing, id);
66 this.mutableIncrementingId += 1;
67 return String(id);
68 } else {
69 return String(this.map.get(thing));
70 }
71 }
72}
73
74function makeSureNodeIsRegistered(graph: Dagre.Graph, idTable: IdTable, stream: Stream<any>) {

Callers 5

buildGraphFunction · 0.95
makeSureNodeIsRegisteredFunction · 0.80
visitOperatorFunction · 0.80
visitEdgeFunction · 0.80
traverseFunction · 0.80

Calls 1

hasMethod · 0.80

Tested by

no test coverage detected