Package epydoc :: Package docwriter :: Module dotgraph
[hide private]
[frames] | no frames]

Module dotgraph
source code

Render Graphviz directed graphs as images. Below are some examples.

Import Graph
Import Graph

Class Hierarchy for apidoc.APIDoc
Class Hierarchy for apidoc.APIDoc

Package Tree for epydoc
Package Tree for epydoc




See Also: The Graphviz Homepage

Classes [hide private]
    Dot Graphs
DotGraph A dot directed graph.
DotGraphNode  
DotGraphEdge  
    Specialized Nodes for UML Graphs
DotGraphUmlClassNode A specialized dot graph node used to display ClassDocs using UML notation.
DotGraphUmlModuleNode A specialized dot grah node used to display ModuleDocs using UML notation.

Functions [hide private]
    Graph Generation Functions
  package_tree_graph(packages, linker, context=None, **options)
Return a DotGraph that graphically displays the package hierarchies for the given packages.
  uml_package_tree_graph(packages, linker, context=None, **options)
Return a DotGraph that graphically displays the package hierarchies for the given packages as a nested set of UML symbols.
  class_tree_graph(bases, linker, context=None, **options)
Return a DotGraph that graphically displays the package hierarchies for the given packages.
  uml_class_tree_graph(class_doc, linker, context=None, **options)
Return a DotGraph that graphically displays the class hierarchy for the given class, using UML notation.
  import_graph(modules, docindex, linker, context=None, **options)
  call_graph(api_docs, docindex, linker, context=None, **options)
    Dot Version
  get_dot_version()
    Helper Functions
  add_valdoc_nodes(graph, val_docs, linker, context)
@todo: Use different node styles for different subclasses of APIDoc
  specialize_valdoc_node(node, val_doc, context, url)
Update the style attributes of node to reflext its type and context.
  name_list(api_docs, context=None)

Variables [hide private]
MODULE_BG  
CLASS_BG  
SELECTED_BG  
BASECLASS_BG  
SUBCLASS_BG  
ROUTINE_BG  
INH_LINK_COLOR  
    Dot Graphs
DOT_COMMAND The command that should be used to spawn dot
    Dot Version
_dot_version  
_DOT_VERSION_RE  
    Helper Functions
NOOP_URL  
MODULE_NODE_HTML  

Function Details [hide private]

package_tree_graph(packages, linker, context=None, **options)

source code 
Return a DotGraph that graphically displays the package hierarchies for the given packages.

uml_package_tree_graph(packages, linker, context=None, **options)

source code 
Return a DotGraph that graphically displays the package hierarchies for the given packages as a nested set of UML symbols.

class_tree_graph(bases, linker, context=None, **options)

source code 
Return a DotGraph that graphically displays the package hierarchies for the given packages.

uml_class_tree_graph(class_doc, linker, context=None, **options)

source code 

Return a DotGraph that graphically displays the class hierarchy for the given class, using UML notation. Options:

  • max_attributes
  • max_operations
  • show_private_vars
  • show_magic_vars
  • link_attributes

import_graph(modules, docindex, linker, context=None, **options)

source code 

call_graph(api_docs, docindex, linker, context=None, **options)

source code 
Parameters:
  • options -
    • dir: rankdir for the graph. (default=LR)
    • add_callers: also include callers for any of the routines in api_docs. (default=False)
    • add_callees: also include callees for any of the routines in api_docs. (default=False)

To Do: Add an exclude option?

get_dot_version()

source code 

add_valdoc_nodes(graph, val_docs, linker, context)

source code 
@todo: Use different node styles for different subclasses of APIDoc

specialize_valdoc_node(node, val_doc, context, url)

source code 
Update the style attributes of node to reflext its type and context.

name_list(api_docs, context=None)

source code 

Variables Details [hide private]

MODULE_BG

Value:
'#d8e8ff'                                                              
      

CLASS_BG

Value:
'#d8ffe8'                                                              
      

SELECTED_BG

Value:
'#ffd0d0'                                                              
      

BASECLASS_BG

Value:
'#e0b0a0'                                                              
      

SUBCLASS_BG

Value:
'#e0b0a0'                                                              
      

ROUTINE_BG

Value:
'#e8d0b0'                                                              
      

INH_LINK_COLOR

Value:
'#800000'                                                              
      

DOT_COMMAND

The command that should be used to spawn dot
Value:
'dot'                                                                  
      

_dot_version

Value:
None                                                                  
      

_DOT_VERSION_RE

Value:
dot version ([\d\.]+)                                                  
      

NOOP_URL

Value:
'javascript: void(0);'                                                 
      

MODULE_NODE_HTML

Value:
'''<TABLE BORDER="0" CELLBORDER="0" CELLSPACING="0"
         CELLPADDING="0" PORT="table" ALIGN="LEFT">
  <TR><TD ALIGN="LEFT" VALIGN="BOTTOM" HEIGHT="8" WIDTH="16" FIXEDSIZE\
="true"
          BGCOLOR="%s" BORDER="1" PORT="tab"></TD></TR>
  <TR><TD ALIGN="LEFT" VALIGN="TOP" BGCOLOR="%s" BORDER="1"
          PORT="body" HREF="%s" TOOLTIP="%s">%s</TD></TR>
  </TABLE>'''