Skip to content
  • Tiago Peixoto's avatar
    Complete re-factoring of python module and command line tool · 8b32d7fc
    Tiago Peixoto authored
    The program was split in two parts:
    
        1. A python module, graph_tool.py, which encapsulates the graph
           manipulation under a Graph class. Now the following can be done:
    
                  import graph_tool
                  g1 = graph_tool.Graph()
                  g2 = graph_tool.Graph()
                  g1.load("foo.xml")
                  g2.load("bar.xml")
                  print g1.number_of_vertices(), g2.number_of_vertices()
    
        2. A standalone command line tool, graph-tool, which imports
           graph_tool.py, and exposes the Graph methods as command line
           options.
    
    The whole command line engine was thus (once again) entirely
    rewritten. It is now Crack-Free™, and simply mirrors the methods of the
    Graph class as command line options, using, for this, the beauty of
    function decorators. It classifies now, I believe, as Pythonic™.
    8b32d7fc