@@ -49,72 +49,6 @@ If you're considering using jsgraph in a commerical product, please get in touch
4949
5050### Programming
5151
52- #### API Overview
53-
54- [ DirectedGraph] ( ./docs/object-DirectedGraph.md ) container class methods:
55-
56- - constructor
57- - getGraphName
58- - setGraphName
59- - getGraphDescription
60- - setGraphDescription
61- - isVertex
62- - addVertex
63- - removeVertex
64- - getVertexProperty
65- - setVertexProperty
66- - hasVertexProperty
67- - clearVertexProperty
68- - inDegree
69- - inEdges
70- - outDegree
71- - outEdges
72- - isEdge
73- - addEdge
74- - removeEdge
75- - getEdgeProperty
76- - setEdgeProperty
77- - hasEdgeProperty
78- - clearEdgeProperty
79- - verticesCount
80- - getVertices
81- - edgesCount
82- - getEdges
83- - rootVerticesCount
84- - getRootVertices
85- - leafVerticesCount
86- - getLeafVertices
87- - toJSON / toObject (alias)
88- - stringify
89- - fromObject
90- - fromJSON
91-
92- Included algorithms:
93-
94- - [ Tranposition] ( ./docs/algorithm-transpose.md ) (flips the direction of edges)
95- - [ Breadth-first visit and search] ( ./docs/algorithm-bft.md ) w/visitor pattern callbacks:
96- - initializeVertex
97- - startVertex
98- - discoverVertex
99- - examineVertex
100- - examineEdge
101- - nonTreeEdge
102- - grayTarget
103- - blackTarget
104- - finishVertex
105- - [ Depth-first visit and search] ( ./docs/algorithm-dft.md ) w/visitor pattern callbacks:
106- - initializeVertex
107- - startVertex
108- - discoverVertex
109- - examineEdge
110- - treeEdge
111- - backEdge
112- - forwardOrCrossEdge
113- - finishVertex
114- - finishEdge
115-
116- #### API Detail
117-
11852- [ Object Reference: DirectedGraph container] ( ./docs/object-DirectedGraph.md )
11953- [ Object Reference: DirectedGraph export object] ( ./docs/object-JSON.md )
12054- [ Transform Reference: jsgraph.directed.transpose] ( ./docs/transform-transpose.md )
@@ -312,7 +246,7 @@ if (response.error) {
312246 console .log (response .error );
313247} else {
314248 digraph = response .result ;
315- console .log (digraph .toJSON ());
249+ console .log (digraph .stringify ());
316250}
317251```
318252
@@ -362,8 +296,9 @@ The `DirectedGraph` container object created by this process models "a graph" ge
362296- ` getRootVertices() ` - retrieve an array of ID strings for all vertices that have in-degree zero
363297- ` leafVerticesCount() ` - obtain count of vertices with out-degree zero
364298- ` getLeafVertices() ` - retrieve an array of ID strings for all vertices that have out-degree zero
365- - ` toObject() ` - serialize the DirectedGraph container to a JavaScript data object
366- - ` toJSON(replacer, space) ` - serialize the DirectedGraph container to a JSON string
299+ - ` toObject() ` - serialize the DirectedGraph container to a JavaScript data object (same as toJSON) ** deprecated in v0.7**
300+ - ` toJSON() ` - serialize the DirectedGraph container to a JavaScript data object (same as toObject)
301+ - ` stringify(replacer, space) ` - serialize the DirectedGraph container to a JSON string
367302- ` fromObject(dataObject) ` - import a jsgraph-format JavaScript data object into the container (addative)
368303- ` fromJSON(jsonString) ` - import jsgraph-format JSON string into the container (addative)
369304
0 commit comments