MCPcopy Create free account
hub / github.com/easy-graph/Easy-Graph / add_nodes

Method add_nodes

easygraph/readwrite/graphml.py:582–587  ·  view source on GitHub ↗
(self, G, graph_element)

Source from the content-addressed store, hash-verified

580 self.attributes[xml_obj].append([k, v, scope, default.get(k)])
581
582 def add_nodes(self, G, graph_element):
583 default = G.graph.get("node_default", {})
584 for node, data in G.nodes.items():
585 node_element = self.myElement("node", id=str(node))
586 self.add_attributes("node", node_element, data, default)
587 graph_element.append(node_element)
588
589 def add_edges(self, G, graph_element):
590 if G.is_multigraph():

Callers 2

add_graph_elementMethod · 0.95
add_graph_elementMethod · 0.45

Calls 2

add_attributesMethod · 0.95
appendMethod · 0.80

Tested by

no test coverage detected