diskimage-builder/diskimage_builder/block_device/level1
Ian Wienand 75817ef205 Use networkx for digraph
This switches the code to use networkx for the digraph implementation.

Note that the old implementation specifically isn't removed in this
change -- for review clarity.  It will be replaced by a base class
that defines things properly to the API described below.

Plugins return a node object with three functions

 get_name() : return the unique name of this node

 get_nodes() : return a list of nodes for insertion into the graph.
  Usually this is just "self".  Some special things like partitioning
  add extra nodes at this point, however.

 get_edges() : return a tuple of two lists; edges_from and edges_to
  As you would expect the first is a list of node names that points to
  us, and the second is a list of node names we point to.  Usually
  this is only populated as ([self.base],[]) -- i.e. our "base" node
  points to us.  Some plugins, such as mounting, create links both to
  and from themselves, however.

Plugins have been updated, some test cases added (error cases
specifically)

Change-Id: Ic5a61365ef0132476b11bdbf1dd96885e91c3cb6
2017-05-26 11:42:10 +10:00
..
__init__.py Add a more generic tree->graph parser 2017-05-26 10:13:14 +10:00
mbr.py Produce API documentation 2017-05-25 14:26:31 +10:00
partition.py Use networkx for digraph 2017-05-26 11:42:10 +10:00
partitioning.py Use networkx for digraph 2017-05-26 11:42:10 +10:00