|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbyucc.jhdl.synth.graph.NamedObject
byucc.jhdl.synth.graph.Vertex
byucc.jhdl.synth.DFVertex
The basic vertex for any DataFlowGraph. This class supports three different types of vertices: signals, constants, and operators. Signals represent named variables. Constants represent constant-valued objects. Operators represent an operation which accepts multiple inputs and generates a single ouput.
DFEdge
,
DataFlowGraph
Field Summary |
Fields inherited from class byucc.jhdl.synth.graph.Vertex |
inEdgeVector, outEdgeVector, parent, visited |
Fields inherited from class byucc.jhdl.synth.graph.NamedObject |
name |
Constructor Summary | |
DFVertex(Graph g,
java.lang.String name)
Construct a new DFVertex of the given name within the given graph. |
|
DFVertex(Graph g,
java.lang.String name,
Wire wire)
Construct a new DFVertex of the given name and associated with the given wire, within the given graph. |
Method Summary | |
java.lang.Object |
getAssociatedReference()
|
Wire |
getAssociatedWire()
|
int |
getBusWidth()
|
int |
getConstantValue()
Get an integer representation of a constant's value. |
java.lang.String |
getDFName()
Get the appropriate name for this vertex. |
DFEdge |
getInputPort(java.lang.String portName)
Get the Edge from this vertex that is connected to the named input port. |
java.lang.String |
getOperation()
Get the operation name for this operator. |
DFEdge |
getOutputPort(java.lang.String portName)
Get the Edge from this vertex that is connected to the named output port. |
DFSubGraph |
getParentalSubGraph()
Get the parentalSubGraph to which this DFVertex belongs. |
java.lang.String |
getProperty(java.lang.String key)
Returns the value associated with the given key. |
java.lang.String |
getSignalBasename()
Get the base name for this signal. |
java.lang.String |
getSignalName()
Get the signal name for this signal. |
boolean |
hasInputPort(java.lang.String portName)
Does this signal have an input edge with the given headPort name. |
boolean |
hasOutputPort(java.lang.String portName)
Does this signal have an output edge with the given tailPort name. |
boolean |
isAnnotation()
Is the current vertex an annotation. |
boolean |
isConstant()
Is the current vertex a constant. |
boolean |
isOperator()
Is the current vertex an operator. |
boolean |
isRegistered()
Is this wire registered? That is, should a register be created and attached to this wire when the graph is synthesized. |
void |
isRegistered(boolean flag)
Set this wire to be registered or not. |
boolean |
isSignal()
Is the current vertex a signale. |
void |
setAssociatedReference(java.lang.Object ref)
|
void |
setAssociatedWire(Wire w)
|
void |
setBusWidth(int width)
|
void |
setConstantValue(int width,
int value)
Set the value for this constant. |
void |
setConstantWidthValue(int width,
int value)
Set the width and value for this constant. |
void |
setOperation(java.lang.String operation)
Set the operation for this operator. |
void |
setProperty(java.lang.String key,
java.lang.String value)
Set a property, (a key->value pair), for this vertex. |
void |
setSignalName(java.lang.String name)
Set the name for this signal. |
void |
setSignalWidthName(int width,
java.lang.String name)
Set the width and name for this signal. |
java.lang.String |
toString()
Generate a String representation of this DFVertex. |
void |
uniquifySignal()
Give this signal a unique name. |
protected java.lang.String |
vertexDotProperties()
|
Methods inherited from class byucc.jhdl.synth.graph.Vertex |
findEdgeTo, getInEdges, getOutEdges, getParent, getSingleHead, getSingleTail, getVisited, inDegree, isAdjacent, isVisited, outDegree, resetVisit, toDot, vertexDotLabels, visit, visit |
Methods inherited from class byucc.jhdl.synth.graph.NamedObject |
getName, setName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public DFVertex(Graph g, java.lang.String name)
g
- The graph (DataFlowGraph) in which this DFVertex should
be created.name
- The name for the new DFVertex.public DFVertex(Graph g, java.lang.String name, Wire wire)
g
- The graph (DataFlowGraph) in which this DFVertex should
be created.name
- The name for the new DFVertex.wire
- A wire to be associated with this vertex.Method Detail |
public DFSubGraph getParentalSubGraph()
public java.lang.String getDFName()
public void setProperty(java.lang.String key, java.lang.String value)
setProperty
in class Vertex
key
- A string representing the key for this property.value
- A string representing the value associated with key.public java.lang.String getProperty(java.lang.String key)
key
- The key of the property of interest.
setProperty(java.lang.String, java.lang.String)
public boolean isConstant()
public boolean isSignal()
public boolean isOperator()
public boolean isAnnotation()
public int getConstantValue()
public java.lang.String getSignalName()
public java.lang.String getSignalBasename()
public java.lang.String getOperation()
public void setConstantValue(int width, int value)
value
- the new value for this constant.public void setConstantWidthValue(int width, int value)
width
- the new width for this constant.value
- the new value for this constant.public void uniquifySignal()
public void setSignalName(java.lang.String name)
name
- the new name for this signal.public void setSignalWidthName(int width, java.lang.String name)
width
- the new width for this signal.name
- the new name for this signal.public void setOperation(java.lang.String operation)
operation
- the new operation for this operator.public Wire getAssociatedWire()
public java.lang.Object getAssociatedReference()
public void setAssociatedWire(Wire w)
public void setAssociatedReference(java.lang.Object ref)
public int getBusWidth()
public void setBusWidth(int width)
public boolean isRegistered()
public void isRegistered(boolean flag)
flag
- A boolean specifying whether this signal should be
registered. That is, if the flag is true then a
register will be inserted at this signal when the
circuit is synthesized. If the flag is false then no
register will be created.public boolean hasInputPort(java.lang.String portName)
portName
- The port name to look for on the input edges.public DFEdge getInputPort(java.lang.String portName)
portName
- The port name of the edge of interest.public boolean hasOutputPort(java.lang.String portName)
portName
- The port name to look for on the output edges.public DFEdge getOutputPort(java.lang.String portName)
portName
- The port name of the edge of interest.protected java.lang.String vertexDotProperties()
vertexDotProperties
in class Vertex
public java.lang.String toString()
toString
in class Vertex
toDot
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |