COIN-OR::LEMON - Graph Library

Changeset 1394:f0c48d7fa73d in lemon-0.x for src/demo


Ignore:
Timestamp:
04/27/05 12:44:58 (19 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@1851
Message:

Modifying the interface.
add -> read, write

Location:
src/demo
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/demo/lp_maxflow_demo.cc

    r1387 r1394  
    7676 
    7777  GraphReader<ListGraph> reader(std::cin,g);
    78   reader.addNode("source",s).addNode("target",t)
    79     .addEdgeMap("capacity",cap).run();
     78  reader.readNode("source",s).readNode("target",t)
     79    .readEdgeMap("capacity",cap).run();
    8080 
    8181  // std::ifstream file("../test/preflow_");
  • src/demo/min_route.cc

    r1358 r1394  
    7070  CoordMap coord(graph);
    7171  XMap<CoordMap> xcoord = xMap(coord);
    72   reader.addNodeMap("coordinates_x", xcoord);
     72  reader.readNodeMap("coordinates_x", xcoord);
    7373  YMap<CoordMap> ycoord = yMap(coord);
    74   reader.addNodeMap("coordinates_y", ycoord);
     74  reader.readNodeMap("coordinates_y", ycoord);
    7575
    7676  LengthMap length(graph);
    77   reader.addEdgeMap("length", length);
     77  reader.readEdgeMap("length", length);
    7878
    7979  Node source, target;
    80   reader.addNode("source", source);
    81   reader.addNode("target", target);
     80  reader.readNode("source", source);
     81  reader.readNode("target", target);
    8282
    8383  reader.run();
Note: See TracChangeset for help on using the changeset viewer.