Package ZenUtils :: Module Graphics :: Class NetworkGraph
[hide private]
[frames] | no frames]

Class NetworkGraph

source code

object --+
         |
        NetworkGraph

This class is a wrapper for pydot functionality. It provides a means of graphically representing nodes in a tree.

Instance Methods [hide private]
 
__init__(self, device=None, node=None, parentName=None)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
simpleProcessNodes(self, node=None, parentName=None, doNets=False, doDevices=False)
This method processes the child nodes of the passed node, and then its children.
source code
 
complexProcessNodes(self)
This method (will) processes nodes and builds the graphs node at a time with actual pydot objects (as opposed to building a graph from a list of edges).
source code
 
setGraphFromEdges(self, edges, directed=True) source code
 
prepare(self, nodeProcessing='simple', edges=None) source code
 
write(self, fdOrPath, format='png') source code
 
render(self, format='png', withNetworks=False)
This will render an image format suitable for display in a browser.
source code

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, device=None, node=None, parentName=None)
(Constructor)

source code 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Overrides: object.__init__
(inherited documentation)

simpleProcessNodes(self, node=None, parentName=None, doNets=False, doDevices=False)

source code 
This method processes the child nodes of the passed node, and then its children. It returns a list of tuples where the tuples represent a simple parent-child relationship.

complexProcessNodes(self)

source code 
This method (will) processes nodes and builds the graphs node at a time with actual pydot objects (as opposed to building a graph from a list of edges). This allows for custom presentation changes based on node attributes.