Skip to content

Commit 9e303e2

Browse files
peterschrammeltautschnig
authored andcommitted
GraphML: add cyclehead node
It's actually not clear whether this is necessary or permitted, it's not contained in the official specification.
1 parent 6d1236d commit 9e303e2

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/xmllang/graphml.cpp

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,20 @@ bool write_graphml(const graphmlt &src, std::ostream &os)
309309
key.new_element("default").data="false";
310310
}
311311

312+
// <key attr.name="cyclehead" attr.type="boolean" for="edge"
313+
// id="cyclehead">
314+
// <default>false</default>
315+
// </key>
316+
{
317+
xmlt &key = graphml.new_element("key");
318+
key.set_attribute("attr.name", "cyclehead");
319+
key.set_attribute("attr.type", "boolean");
320+
key.set_attribute("for", "edge");
321+
key.set_attribute("id", "cyclehead");
322+
323+
key.new_element("default").data = "false";
324+
}
325+
312326
// <key attr.name="threadId" attr.type="string" for="edge" id="threadId"/>
313327
// TODO: format for multi-threaded programs not defined yet
314328
{

0 commit comments

Comments
 (0)