MCPcopy Create free account
hub / github.com/Linloir/GraphBuilder / ConvertToAL

Method ConvertToAL

graph_implement.cpp:1007–1020  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1005}
1006
1007ALGraph* AMLGraph::ConvertToAL(){
1008 ALGraph *converted = new ALGraph(type);
1009 for(int i = 0; i < outVexList.size(); i++)
1010 converted->AddVex(outVexList[i].info);
1011 for(int i = 0; i < outVexList.size(); i++){
1012 AMLArc *p = outVexList[i].firstArc;
1013 while(p != nullptr){
1014 if(p->outVexID == i)
1015 converted->AddArc(p->gArc);
1016 p = p->outVexID == i ? p->nextOutArc : p->nextInArc;
1017 }
1018 }
1019 return converted;
1020}

Callers 1

CreateSettingsMethod · 0.80

Calls 2

AddVexMethod · 0.80
AddArcMethod · 0.80

Tested by

no test coverage detected