edu.byu.ece.graph
Class AbstractGraphToDotty

java.lang.Object
  extended by edu.byu.ece.graph.AbstractGraphToDotty

public class AbstractGraphToDotty
extends java.lang.Object


Nested Class Summary
static class AbstractGraphToDotty.ArrowHead
           
static class AbstractGraphToDotty.Color
           
static class AbstractGraphToDotty.Shape
           
static class AbstractGraphToDotty.Style
           
 
Field Summary
protected  java.util.HashMap<java.lang.Object,java.lang.String> _nodeMap
           
 
Constructor Summary
AbstractGraphToDotty()
           
 
Method Summary
static void addColor(java.lang.StringBuffer sb, AbstractGraphToDotty.Color color)
           
static void addDefaultNodeStyle(java.lang.StringBuffer sb, AbstractGraphToDotty.Color color, AbstractGraphToDotty.Shape shape)
           
 void addEdgeLabel(java.lang.StringBuffer sb, Edge edge)
           
static void addEdgeName(java.lang.StringBuffer sb, java.lang.String src, java.lang.String sink)
           
static void addFillColor(java.lang.StringBuffer sb, AbstractGraphToDotty.Color color)
           
 void addNodeLabel(java.lang.StringBuffer sb, java.lang.Object node)
           
 void addNodeLabel(java.lang.StringBuffer sb, java.lang.Object node, java.lang.String color, java.lang.String shape)
           
static void addNodeName(java.lang.StringBuffer sb, java.lang.String nodeName)
           
static void addRank(java.lang.StringBuffer sb, java.util.Collection<java.lang.String> list)
           
static void addStyle(java.lang.StringBuffer sb, AbstractGraphToDotty.Style style)
           
static java.lang.String convertSpecialsToEscapes(java.lang.String str)
           
 java.lang.String createColoredDottyBody(AbstractGraph graph, java.util.Collection<java.util.Collection> nodeCollections)
           
 java.lang.String createDottyBody(AbstractGraph graph)
           
 java.lang.String createDottyBody(AbstractGraph graph, java.util.Map<EdifNet,java.util.Set<EdifCellInstance>> eciMap)
           
 java.lang.String edge2Dotty(Edge edge)
           
 java.lang.String edgeProperties(Edge edge)
           
 java.lang.String footer()
           
static void graphToDotty(AbstractGraph graph, java.lang.String filename)
           
 java.lang.String header()
           
 java.lang.String node2Dotty(java.lang.Object node)
           
 java.lang.String nodeProperties(java.lang.Object node)
           
 java.lang.String nodeProperties(java.lang.Object node, java.lang.String color, java.lang.String shape)
           
static void printFile(java.lang.String filename, java.lang.String data)
           
 java.lang.String writeDottyEdges(AbstractGraph graph)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_nodeMap

protected java.util.HashMap<java.lang.Object,java.lang.String> _nodeMap
Constructor Detail

AbstractGraphToDotty

public AbstractGraphToDotty()
Method Detail

addColor

public static void addColor(java.lang.StringBuffer sb,
                            AbstractGraphToDotty.Color color)

addEdgeLabel

public void addEdgeLabel(java.lang.StringBuffer sb,
                         Edge edge)

addEdgeName

public static void addEdgeName(java.lang.StringBuffer sb,
                               java.lang.String src,
                               java.lang.String sink)

addFillColor

public static void addFillColor(java.lang.StringBuffer sb,
                                AbstractGraphToDotty.Color color)

addNodeLabel

public void addNodeLabel(java.lang.StringBuffer sb,
                         java.lang.Object node)

addNodeLabel

public void addNodeLabel(java.lang.StringBuffer sb,
                         java.lang.Object node,
                         java.lang.String color,
                         java.lang.String shape)

addNodeName

public static void addNodeName(java.lang.StringBuffer sb,
                               java.lang.String nodeName)

addDefaultNodeStyle

public static void addDefaultNodeStyle(java.lang.StringBuffer sb,
                                       AbstractGraphToDotty.Color color,
                                       AbstractGraphToDotty.Shape shape)

addRank

public static void addRank(java.lang.StringBuffer sb,
                           java.util.Collection<java.lang.String> list)

addStyle

public static void addStyle(java.lang.StringBuffer sb,
                            AbstractGraphToDotty.Style style)

createColoredDottyBody

public java.lang.String createColoredDottyBody(AbstractGraph graph,
                                               java.util.Collection<java.util.Collection> nodeCollections)

createDottyBody

public java.lang.String createDottyBody(AbstractGraph graph,
                                        java.util.Map<EdifNet,java.util.Set<EdifCellInstance>> eciMap)

createDottyBody

public java.lang.String createDottyBody(AbstractGraph graph)

convertSpecialsToEscapes

public static java.lang.String convertSpecialsToEscapes(java.lang.String str)

edge2Dotty

public java.lang.String edge2Dotty(Edge edge)

edgeProperties

public java.lang.String edgeProperties(Edge edge)

footer

public java.lang.String footer()

graphToDotty

public static void graphToDotty(AbstractGraph graph,
                                java.lang.String filename)

header

public java.lang.String header()

node2Dotty

public java.lang.String node2Dotty(java.lang.Object node)

nodeProperties

public java.lang.String nodeProperties(java.lang.Object node,
                                       java.lang.String color,
                                       java.lang.String shape)

nodeProperties

public java.lang.String nodeProperties(java.lang.Object node)

printFile

public static void printFile(java.lang.String filename,
                             java.lang.String data)

writeDottyEdges

public java.lang.String writeDottyEdges(AbstractGraph graph)