|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbyucc.jhdl.base.Nameable
byucc.jhdl.base.Node
byucc.jhdl.base.Cell
The Cell class extends the Node
class to provide
named-port and generic-width capability. Cells are connected via
Wires
.
Field Summary | |
static java.lang.Class |
BOOLEAN
Constants useful in in() , out() ,
and so forth. |
static java.lang.String |
CELL_NAME_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static boolean |
CellInterfaceDeterminesUniqueNetlistStructure
A constant useful in pushHierarchy(byucc.jhdl.base.CellInterface[], java.lang.String) |
static int |
DETERMINE_FROM_STRING
This constant provides support for BVs. |
static java.lang.String |
GENERICS_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
protected static CellInterface[] |
implicit_interface
This defines a blank implicit interface. |
static java.lang.String |
IMPLICIT_INTERFACE_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static java.lang.Class |
INTEGER
Constants useful in in() , out() ,
and so forth. |
static java.lang.String |
INTERFACE_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static java.lang.Class |
LONG
Constants useful in in() , out() ,
and so forth. |
static java.lang.String |
PORT_IOS_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static java.lang.String |
PORT_NAMES_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static java.lang.String |
PORT_NET_NAMES_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static java.lang.String |
PORT_PROPERTIES
These are the actual field names for the field that comprise the Cell port interface. |
static java.lang.String |
PORT_WIDTHS_DECLARATION
These are the actual field names for the field that comprise the Cell port interface. |
static boolean |
SIGN_EXT
This constant provides support for BVs. |
static java.lang.Class |
STRING
Constants useful in in() , out() ,
and so forth. |
static boolean |
ZERO_PAD
This constant provides support for BVs. |
Constructor Summary | |
protected |
Cell(Node parent)
Constructor for Cell that works with no name supplied. |
protected |
Cell(Node parent,
java.lang.String name)
Base constructor for Cell. |
Method Summary | |
void |
addPort(CellInterface portInterface)
Adds a port to the cell, after it has been created. |
void |
addPorts(CellInterface[] portInterfaces)
Adds an array of ports to the cell, after it has been created. |
void |
addProperties(PropertyList plist)
Used to add a list of properties to the Cell. |
void |
addProperties(PropertyList plist,
boolean warn_duplicates)
Used to add a list of properties to the Cell. |
Cell |
addProperty(Property p)
Used to add a Property object to the Cell. |
Cell |
addProperty(java.lang.String name,
java.lang.Object value)
Used to add an arbitrary property to a Cell. |
Cell |
addProperty(java.lang.String name,
java.lang.Object value,
boolean isVisible)
|
Cell |
addProperty(java.lang.String name,
java.lang.String value)
Used to add a string property to a Cell. |
protected boolean |
antecedantIsBehaviorallyModeled()
Simple flag tells the cell that one of its antecedants is behaviorally modeled. |
protected boolean |
antecedantIsBehaviorallyModeled(boolean flag)
Used to set or clear the flag that indicates that a cell's antecedant is behaviorally modeled. |
boolean |
behavioralModelIsAvailable()
Used to tell if a cell has a behavioral simulation model associated with it. |
void |
bind(java.lang.String name,
boolean value)
Binds a boolean parameter. |
void |
bind(java.lang.String name,
int value)
Binds an integer parameter. |
void |
bind(java.lang.String name,
long value)
Binds a long parameter. |
void |
bind(java.lang.String name,
java.lang.Object value)
Binds a declared generic variable with a value. |
protected boolean |
cellInterfaceDeterminesUniqueNetlistStructure()
When false, the default behavior of this method, each cell will list itself separately in a netlist, guaranteeing that the netlist will not have invalid data at the expense of a larger file-size. |
static CellInterface |
clk(java.lang.String name)
Creates the declaration for a clk-port, to be used in the CellInterface[]. |
Wire |
connect(java.lang.String portname,
Wire w)
Attaches the wire to an input or output port by name, using the information in portios to determine the direction of the port. |
void |
connectAllWires(ArgBlockList arg_list)
Wires up all of the wires in the ArgBlockList to all of the named ports using the associations given them when they were put in the ArgBlockList. |
Wire |
connectOptional(java.lang.String portname,
Wire w)
Attaches the wire to an input port, only if the wire isn't null. |
SubCell |
constructSubCell(Node parent,
java.lang.String name)
This call is used to determine which underlying class is created in pushHierarchy . |
SubCell |
constructSubCellNoImplicitPorts(Node parent,
java.lang.String name)
This call is used to determine which underlying class is created in pushHierarchyNoImplicitPorts(CellInterface[], String, boolean, String) . |
protected boolean |
defaultSimulationModelIsBehavioral()
States whether the default simulation model is behavioral (which it is for everything but Structural cells. |
void |
disableAllBehavioralModels()
This method will disable all behavioral models defined for everything but the leaf cells of a cell. |
void |
disableBehavioralModel()
This disables this cell's behavioral model. |
void |
enableBehavioralModel()
This is used to enable a behavioral model on a cell. |
java.lang.Object |
getArgument(java.lang.String name)
This retrieves an argument of a generic binding. |
java.lang.String |
getAttachedPort(Wire w)
Used to access the portname that a wire is attached to. |
Wire |
getAttachedWire(java.lang.String portname)
Used to find the wire that is attached to a port. |
Wire |
getAttachedWireNoException(java.lang.String portname)
Performs exactly the same function as getAttachedWire(String) but
will not throw an exception if the wire is not found. |
java.lang.String |
getCellName()
Access the cell name associated with a derived class. |
Netlist |
getCellNetlist()
Builds a netlist for the given cell that contains all of the atomic wires located at this level along with the cells that they are connected to. |
Netlist |
getCellNetList()
Deprecated. Use getCellNetlist() |
Netlist |
getCellNetlist(boolean atomic)
Builds a netlist for the given cell that contains all of the wires located at this level along with the cells that they are connected to. |
Netlist |
getCellNetlist(boolean atomic,
boolean filter)
Builds a netlist for the given cell that contains all of the wires located at this level along with the cells that they are connected to. |
CellList |
getDescendents()
Returns a CellList containing all descendents of this cell. |
FlatNetlist |
getFlatNetlist()
Builds a flat netlist for the given cell that contains all of the wires and leaf cells connected by the subtree of the cell. |
CellList |
getFlatNetlistableChildren()
Grabs the netlistable leaf descendents of this cell, if any exist |
int |
getGeneric(java.lang.String name)
Deprecated. use getArgument(String) |
int |
getHeight()
Get the height of the current cell in terms of "Atomic FPGA units". |
CellList |
getNetlistableChildren()
Grabs only the netlistable children of this cell, if any exist |
PlacementInfo |
getPlacementInfo()
Get the PlacementInfo object associated with this cell. |
Property[] |
getPortProperties()
Access the array of port properties associated with a derived class. |
PortRecord |
getPortRecord(java.lang.String portname)
This will return a single port record describing the attributes of the named port. |
PortRecordList |
getPortRecords()
This method is used to access all information on a Cell's ports. |
PropertyList |
getProperties()
Used to get the property list from the cell. |
Property |
getProperty(java.lang.String name)
|
java.lang.Object |
getPropertyValue(java.lang.String name)
|
WireList |
getSinkWires()
Returns a list containing all of the sink wires for this Cell. |
WireList |
getSourceWires()
Returns a list containing all of the source wires for this Cell. |
java.lang.Class |
getSubCellClass()
This call is used to determine which class is created by constructSubCell. |
java.lang.String |
getUniqueCellName()
Returns a String that is unique for this particular class, generic bindings, and placement info. |
int |
getWidth()
Get the width of the current cell in terms of "Atomic FPGA units". |
int |
getX()
Get the X location of where this cell is placed within its parent. |
int |
getY()
Get the Y location of where this cell is placed within its parent. |
boolean |
hasBeenTraced()
Used to flag if this cell has been traced in topological sorting. |
boolean |
hasBeenTraced(boolean flag)
Used to flag if this cell has been traced in topological sorting. |
abstract boolean |
hasBehaviorInClockMethod()
Returns true iff this cell has a Clockable.clock() and Clockable.reset()
method that are called as part of the circuit's current behavioral model. |
abstract boolean |
hasBehaviorInPropagateMethod()
Returns true iff this cell has a Propagateable#propagate() method that is called
as part of the circuit's current behavioral model. |
boolean |
hasPort(java.lang.String portname)
Used to check if a cell contains a port by the given name. |
boolean |
hasPorts()
Only test benches are allowed not to have ports. |
static CellInterface |
in(java.lang.String name,
int width)
Creates the declaration for an in-port, to be used in the CellInterface[] |
static CellInterface |
in(java.lang.String name,
java.lang.String width)
Creates the declaration for an in-port, to be used in the CellInterface[] |
static CellInterface |
inout(java.lang.String name,
int width)
Creates the declaration for an inout-port, to be used in the CellInterface[] |
static CellInterface |
inout(java.lang.String name,
java.lang.String width)
Creates the declaration for an inout-port, to be used in the CellInterface[] |
boolean |
isAsynchronouslyScheduled()
Used to check if this node is on the propagate list. |
boolean |
isAsynchronouslyScheduled(boolean flag)
Used to flag if this node is on the propagate list. |
boolean |
isAsynchronousSourceSinkResolved()
|
boolean |
isBehaviorallyModeled()
Simple flag tells the cell that it is currently being behaviorally modeled. |
protected boolean |
isBehaviorallyModeledBranch()
Checks both behaviorally_modeled flag and antecedant_is_behaviorally_modeled. |
boolean |
isInput(java.lang.String portname)
Returns true if the attached wire of the given port is actually an input. |
boolean |
isLeafCell()
Easy way for others, e.g., the netlister, to see if this is a leaf cell To treat a cell as a leaf when it is not, override isNetlistLeaf() . |
boolean |
isNetlistable()
Determine whether the user wants the cell to netlist. |
boolean |
isNetlistable(boolean flag)
This method sets whether a cell is netlistable. |
boolean |
isNetlistablePort(int port_index)
Determine whether the user wants the port to netlist. |
boolean |
isNetlistLeaf()
A few rare cells are leafCells during netlisting, but not during simulation. |
boolean |
isNotNetlistable()
Determine whether the user wants the cell to netlist. |
boolean |
isNotNetlistablePort(int port_index)
Determine whether the user wants the port to netlist. |
boolean |
isNotVisible()
Determine whether the user wants the cell to show up in a browser, like JAB. |
boolean |
isOutput(java.lang.String portname)
Returns true if the attached wire of the given port is actually an output. |
boolean |
isPlaceable()
Returns whether this cell is placeable. |
void |
isPlaceable(boolean p)
Returns whether this cell is placeable. |
boolean |
isPlaced()
Returns whether this cell is placed. |
void |
isPlaced(boolean p)
Sets whether this cell is placed. |
boolean |
isPlacementLocked()
Returns whether placement on this cell is locked. |
boolean |
isRoot()
Returns false, as no Cell can be the root (use HWSystem for the root). |
boolean |
isSimulateable()
Determine whether the user wants the cell to be simulated (default true). |
boolean |
isSimulateable(boolean flag)
Sets whether a cell should be simulated (default true). |
protected boolean |
isSink()
The simulator needs to be able to tell who is being simulated and who is not. |
protected boolean |
isSource()
The simulator needs to be able to tell who is being simulated and who is not. |
boolean |
isVisible()
Determine whether the user wants the cell to show up in a browser, like JAB. |
boolean |
isVisible(boolean flag)
This method sets whether a cell is visible, such as in browsers like JAB. |
void |
join(Wire w1,
Wire w2)
The user can call this to join two wires together. |
void |
lockPlacement(boolean locked)
Sets the placement lock status of this cell. |
static Wire |
nc(Wire w)
Marks a given wire as a place-holder wire, to be passed to both in and out ports to represent the NC condition of no electrical tie. |
abstract boolean |
needsToBeAsynchronouslyScheduled()
This needs to be implemented in the derived class to actually tell if a cell needs to be propagated or not. |
static CellInterface |
out(java.lang.String name,
int width)
Creates the declaration for an out-port, to be used in the CellInterface[] |
static CellInterface |
out(java.lang.String name,
java.lang.String width)
Creates the declaration for an out-port, to be used in the CellInterface[] |
static CellInterface |
param(java.lang.String name,
java.lang.Class type)
Creates the declaration of a Parameter, to be used in the CellInterface[] |
void |
popHierarchy()
This allows multiple levels of hierarchy within one class file, works in tandem with #pushHierarchy() . |
static CellInterface |
port(java.lang.String name,
int width,
int type)
Creates the declaration for a port, to be used in the CellInterface[]. |
static CellInterface |
port(java.lang.String name,
java.lang.String width,
int type)
Creates the declaration for a port, to be used in the CellInterface[]. |
Wire |
port(java.lang.String name,
Wire wire)
Deprecated. use connect(String, Wire) |
protected boolean |
postorderCheck()
Used to check validity of this cell after recursing down. |
protected boolean |
preorderCheck()
Used to check validity of this cell before recursing down. |
Cell |
pushHierarchy(CellInterface[] cell_interface,
java.lang.String cellname)
This allows multiple levels of hierarchy within one class file |
Cell |
pushHierarchy(CellInterface[] cell_interface,
java.lang.String cellname,
boolean unique_structure)
This allows multiple levels of hierarchy within one class file |
Cell |
pushHierarchy(CellInterface[] cell_interface,
java.lang.String cellname,
boolean unique_structure,
java.lang.String instance_name)
This allows multiple levels of hierarchy within one class file, works in tandem with popHierarchy() . |
Cell |
pushHierarchy(CellInterface[] cell_interface,
java.lang.String cellname,
java.lang.String instance_name)
This allows multiple levels of hierarchy within one class file |
Cell |
pushHierarchyNoImplicitPorts(CellInterface[] cell_interface,
java.lang.String cellname,
boolean unique_structure)
This call begins the creation of a subcell with no implicit ports inherited from any parent cell. |
Cell |
pushHierarchyNoImplicitPorts(CellInterface[] cell_interface,
java.lang.String cellname,
boolean unique_structure,
java.lang.String instance_name)
This call begins the creation of a subcell with no implicit ports inherited from any parent cell. |
void |
removeAllUnconnectedPorts()
|
void |
removePort(java.lang.String portname)
Removes a port from the cell, after it has been created. |
boolean |
removeProperty(java.lang.String name)
Used to remove a named property of a Cell. |
Cell |
replaceProperty(Property p)
Used to replace a property of a Cell. |
Cell |
replaceProperty(java.lang.String name,
java.lang.String value)
Used to replace a string property of a Cell. |
void |
resetBehavioralModelsToDefaults()
This resets all of the behavioral models from this cell down, to their defaults. |
void |
setAsynchronousSourceSinkResolved(boolean yes)
|
void |
setGeneric(java.lang.String name,
int value)
Deprecated. use bind(String, int) |
void |
setHeight(int h)
Sets the height of the cell. |
void |
setNotNetlistable()
Deprecated. Use isNetlistable(false) |
void |
setNotNetlistable(boolean flag)
Deprecated. Use isNetlistable(!flag) |
void |
setNotVisible()
Deprecated. Use isVisible(false) |
void |
setNotVisible(boolean flag)
Deprecated. Use isVisible(!flag) |
void |
setPlacementInfo(PlacementInfo pi)
Set the PlacementInfo object associated with this cell. |
void |
setPortNotNetlistable(java.lang.String portname)
This method is used to change whether a port is netlistable. |
void |
setPortNotNetlistable(java.lang.String portname,
boolean flag)
This method is used to change whether a port is netlistable. |
Property |
setProperty(java.lang.String name,
java.lang.Object value,
boolean isVisible)
|
void |
setWidth(int w)
Sets the width of the cell. |
protected void |
subClassDelete()
Overrides Node to do a more thorough job of deletion. |
java.lang.String |
toString()
Provides a string representation for debug. |
void |
uniquifyCell()
Forces an individual cell to be uniquified, overriding whatever cellInterfaceDeterminesUniqueNetlistStructure() returns. |
int |
userDefinedClockCount()
Returns the number of user-defined clocks belonging to this cell's system. |
static void |
verifyAndCleanup()
This method cleans up all building status flags in preparation for simulation or netlisting. |
Methods inherited from class byucc.jhdl.base.Node |
addObservable, addSimulatorCallback, checkAll, delete, getBuildingFlag, getChildren, getChildrenEnumeration, getDefaultClock, getInstanceName, getParent, getParentCell, getRelatives, getSystem, getWires, optimize, orphanAllowed, printAllChildren, printTree, removeSimulatorCallback, setDefaultClock |
Methods inherited from class byucc.jhdl.base.Nameable |
caseSensitivity, caseSensitivity, disableNameClashChecking, getFullName, getFullNameNoTestBench, getHierNameNoTestBench, getInstanceNo, getInstanceNumber, getLeafName, getLeafName, getRelativeName, getUserName, getUserName, hasUserSpecifiedName, isDescendantOf, setInstanceNumber |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String PORT_NAMES_DECLARATION
public static final java.lang.String PORT_WIDTHS_DECLARATION
public static final java.lang.String PORT_IOS_DECLARATION
public static final java.lang.String PORT_NET_NAMES_DECLARATION
public static final java.lang.String PORT_PROPERTIES
public static final java.lang.String CELL_NAME_DECLARATION
public static final java.lang.String GENERICS_DECLARATION
public static final java.lang.String INTERFACE_DECLARATION
public static final java.lang.String IMPLICIT_INTERFACE_DECLARATION
protected static CellInterface[] implicit_interface
public static final int DETERMINE_FROM_STRING
public static final boolean ZERO_PAD
public static final boolean SIGN_EXT
public static boolean CellInterfaceDeterminesUniqueNetlistStructure
pushHierarchy(byucc.jhdl.base.CellInterface[], java.lang.String)
public static final java.lang.Class INTEGER
in()
, out()
,
and so forth.
public static final java.lang.Class BOOLEAN
in()
, out()
,
and so forth.
public static final java.lang.Class STRING
in()
, out()
,
and so forth.
public static final java.lang.Class LONG
in()
, out()
,
and so forth.
Constructor Detail |
protected Cell(Node parent, java.lang.String name)
parent
- the structural parent for the cell being constructed.name
- the user-defined name of this Cell. May be set to null if no user-defined
name is desired.protected Cell(Node parent)
parent
- the parent of this cell.Method Detail |
public boolean hasPorts()
public void bind(java.lang.String name, int value)
bind(String, Object)
which does the real work.
public void bind(java.lang.String name, long value)
bind(String, Object)
which does the real work.
public void bind(java.lang.String name, boolean value)
bind(String, Object)
which does the real work.
public void bind(java.lang.String name, java.lang.Object value)
name
- the name of the generic variable you want to set.value
- the value you want to set it to.
BuildException
- if the name was not declared or has already been bound.public int getGeneric(java.lang.String name)
getArgument(String)
name
- the name of the binding that you are trying to retrieve.
UnboundException
- if the name is not bound.public java.lang.Object getArgument(java.lang.String name)
name
- the name of the binding to look up
UnboundException
- if the name is not bound.public final void uniquifyCell()
cellInterfaceDeterminesUniqueNetlistStructure()
returns.
public final void addPort(CellInterface portInterface)
portInterface
- the port to add
BuildException
- if port name clashes, or if argument is not a Portpublic final void addPorts(CellInterface[] portInterfaces)
portInterfaces
- the ports to add
BuildException
- if port name clashes, or if array contains non-Portpublic final void removePort(java.lang.String portname)
portname
- the name of the port to remove
BuildException
- if portname is not an existing portpublic final Wire getAttachedWire(java.lang.String portname)
portname
- the portname of interest.
BuildException
- if there is no port by that namepublic final Wire getAttachedWireNoException(java.lang.String portname)
getAttachedWire(String)
but
will not throw an exception if the wire is not found. Used in cases where you
want to search for something but bring down the system if it is not found.
portname
- the portname of interest.
public final java.lang.String getAttachedPort(Wire w)
w
- the wire of interest.
public boolean isInput(java.lang.String portname)
portname
- the name of the port to check
public boolean isOutput(java.lang.String portname)
portname
- the name of the port to check
public void setPortNotNetlistable(java.lang.String portname)
setPortNotNetlistable(String, boolean)
public void setPortNotNetlistable(java.lang.String portname, boolean flag)
flag
- default of false, set to true means port is ignored in netlistpublic boolean isNotNetlistablePort(int port_index)
port_index
- the index of the port name to check
public final boolean isNetlistablePort(int port_index)
port_index
- the index of the port name to check
public void setNotNetlistable()
isNetlistable(false)
public void setNotNetlistable(boolean flag)
isNetlistable(!flag)
flag
- default of false, set to true means cell is ignored in netlistpublic boolean isNetlistable(boolean flag)
isVisible(boolean)
flag
- the value of the netlistable flag: true = netlistable,
false = exclude from netlists
public final boolean isNetlistable()
public final boolean isNotNetlistable()
public void setNotVisible()
isVisible(false)
public void setNotVisible(boolean flag)
isVisible(!flag)
flag
- default of false, set to true means cell is ignored in browserspublic boolean isVisible(boolean flag)
isNetlistable(boolean)
flag
- the new value of the visibility flag
public boolean isVisible()
public final boolean isNotVisible()
public final boolean isSimulateable(boolean flag)
flag
- the new value of the simulateable flag
public final boolean isSimulateable()
public Property[] getPortProperties()
CellInterfaceException
- if portproperties is declared incorrectly.public java.lang.String getCellName()
CellInterfaceException
- if cellname is not declared or declared incorrectly.public final java.lang.String getUniqueCellName()
public final boolean isLeafCell()
isNetlistLeaf()
.
public boolean isNetlistLeaf()
protected boolean cellInterfaceDeterminesUniqueNetlistStructure()
public final CellList getNetlistableChildren()
public final CellList getFlatNetlistableChildren()
public Wire connect(java.lang.String portname, Wire w)
portname
- name of the port.w
- the wire to be attached to the named port.
public Wire connectOptional(java.lang.String portname, Wire w)
portname
- name of the port.w
- the wire to be attached to the port if it's not null.
public void connectAllWires(ArgBlockList arg_list)
arg_list
- all of the wire-port associations that need to be carried out. May
also contain any other argument bindings to be handled manually by the user.ArgBlockList
public void removeAllUnconnectedPorts()
public final WireList getSourceWires()
public final WireList getSinkWires()
protected boolean preorderCheck()
preorderCheck
in class Node
Node#checkAllNodes().
protected boolean postorderCheck()
postorderCheck
in class Node
Node#checkAllNodes().
protected void subClassDelete()
subClassDelete
in class Node
protected boolean isSource()
protected boolean isSink()
public Netlist getCellNetList()
getCellNetlist()
public Netlist getCellNetlist()
public Netlist getCellNetlist(boolean atomic)
atomic
- true for all nets to be atomic, false for nets to be busses
public Netlist getCellNetlist(boolean atomic, boolean filter)
atomic
- true for all nets to be atomic, false for nets to be bussesfilter
- true if we want all non-netlistable cells to not be
included in the net list.
public FlatNetlist getFlatNetlist()
FlatNetlist
object for the given cell.public Cell replaceProperty(java.lang.String name, java.lang.String value)
name
- the name of the property to add or replacevalue
- the new value of the property
public Cell replaceProperty(Property p)
p
- the new version of the property
public boolean removeProperty(java.lang.String name)
name
- the name of the property to remove
public Cell addProperty(java.lang.String name, java.lang.Object value)
name
- the name of the property.value
- the value of the property.
BuildException
- if the property already existspublic Cell addProperty(java.lang.String name, java.lang.Object value, boolean isVisible)
public Property setProperty(java.lang.String name, java.lang.Object value, boolean isVisible)
public Cell addProperty(java.lang.String name, java.lang.String value)
name
- the name of the property.value
- the string value of the property.
BuildException
- if the property already existspublic Cell addProperty(Property p)
p
- the property object.
BuildException
- if the property already existspublic PropertyList getProperties()
public Property getProperty(java.lang.String name)
public java.lang.Object getPropertyValue(java.lang.String name)
public void addProperties(PropertyList plist)
plist
- the list of properties to add.
BuildException
- if a property already existspublic void addProperties(PropertyList plist, boolean warn_duplicates)
plist
- the list of properties to add.warn_duplicates
- true to have an exception on duplicates, false to
force an override of any duplicates
BuildException
- if a property already exists and warn_duplicates is truepublic java.lang.String toString()
toString
in class Node
public PortRecord getPortRecord(java.lang.String portname)
portname
- the name of the port to find
public PortRecordList getPortRecords()
for further information.
public final boolean hasPort(java.lang.String portname)
Nameable.caseSensitivity()
for case sensitive behavior.
portname
- the name of the port to check for.
public void enableBehavioralModel()
NoBehavioralModelException
- if there is no behavioral model at this level.public void disableBehavioralModel() throws NoBehavioralModelException
enableBehavioralModel()
.
NoBehavioralModelException
- if there is no fallback model availablepublic void resetBehavioralModelsToDefaults()
public void disableAllBehavioralModels()
public final boolean isBehaviorallyModeled()
protected final boolean antecedantIsBehaviorallyModeled(boolean flag)
flag
- the new value to use for the behaviorally modeled flag
protected final boolean antecedantIsBehaviorallyModeled()
protected final boolean isBehaviorallyModeledBranch()
isBehaviorallyModeled()
|| antecedantIsBehaviorallyModeled()
protected boolean defaultSimulationModelIsBehavioral()
public boolean behavioralModelIsAvailable()
public abstract boolean needsToBeAsynchronouslyScheduled()
public final boolean isAsynchronouslyScheduled()
public final boolean isAsynchronouslyScheduled(boolean flag)
flag
- should be true if the Node is on the list, false otherwise.
public final boolean hasBeenTraced()
public final boolean hasBeenTraced(boolean flag)
flag
- the new value of the tracing flag
public static final CellInterface port(java.lang.String name, int width, int type)
name
- the name of the port (should not be null)width
- the width of the porttype
- the kind of port (IN_PORT|OUT_PORT)| CLK_PORT | ASYNC_PORT | SYNC_PORT
public static final CellInterface port(java.lang.String name, java.lang.String width, int type)
name
- the name of the port (should not be null)width
- the width of the porttype
- the kind of port (IN_PORT|OUT_PORT)| CLK_PORT | ASYNC_PORT | SYNC_PORT
public static final CellInterface in(java.lang.String name, int width)
name
- the name of the port (should not be null)width
- the width of the port
public static final CellInterface in(java.lang.String name, java.lang.String width)
name
- the name of the port (should not be null)width
- the width of the port (should not be null)
public static final CellInterface out(java.lang.String name, int width)
name
- the name of the port (should not be null)width
- the width of the port
public static final CellInterface out(java.lang.String name, java.lang.String width)
name
- the name of the port (should not be null)width
- the width of the port (should not be null)
public static final CellInterface clk(java.lang.String name)
name
- the name of the port (should not be null)
public static final CellInterface inout(java.lang.String name, int width)
name
- the name of the port (should not be null)width
- the width of the port
public static final CellInterface inout(java.lang.String name, java.lang.String width)
name
- the name of the port (should not be null)width
- the width of the port (should not be null)
public static final CellInterface param(java.lang.String name, java.lang.Class type)
name
- the name of the parameter (should not be null)type
- the Class of the parameter (should not be null)
public void join(Wire w1, Wire w2)
Wire#join(Cell, w1, w2)
to get the work done. The Cell method provides
easy access to the current cell where join is being called. This is necessary so
that join can easily find all of the necessary wires that need to be modified.
w1
- the first wirew2
- the second wirepublic Cell pushHierarchyNoImplicitPorts(CellInterface[] cell_interface, java.lang.String cellname, boolean unique_structure)
pushHierarchy(CellInterface[], String, boolean)
.
cell_interface
- the complete interface of the new subcellcellname
- the name of the new subcellunique_structure
- whether the cell can be shared. Compare
#CellInterfaceDeterminesUniqueNetlistStructure()
.
BuildException
- if there is a problempublic Cell pushHierarchyNoImplicitPorts(CellInterface[] cell_interface, java.lang.String cellname, boolean unique_structure, java.lang.String instance_name)
pushHierarchy(CellInterface[], String, boolean, String)
.
cell_interface
- the complete interface of the new subcellcellname
- the "class" name of the new subcell typeunique_structure
- whether the cell can be shared. Compare
#CellInterfaceDeterminesUniqueNetlistStructure()
.instance_name
- the instance name of the new subcell
BuildException
- if there is a problempublic void setGeneric(java.lang.String name, int value)
bind(String, int)
name
- the name of the parameter to bindvalue
- the value of the parameterpublic int getX()
public int getY()
public int getWidth()
public int getHeight()
public void isPlaceable(boolean p)
p
- the new value of the placeable status of the cellpublic boolean isPlaceable()
public void setPlacementInfo(PlacementInfo pi)
pi
- A new PlacementInfo
object to be associated with this cellpublic PlacementInfo getPlacementInfo()
PlacementInfo
object of current cellpublic void setWidth(int w)
w
- the new widthpublic void setHeight(int h)
h
- the new heightpublic void isPlaced(boolean p)
p
- the new value of placement statuspublic boolean isPlaced()
public boolean isPlacementLocked()
public void lockPlacement(boolean locked)
locked
- the new value of the lock statuspublic Wire port(java.lang.String name, Wire wire)
connect(String, Wire)
name
- the name of the port to connectwire
- the wire to connectpublic static void verifyAndCleanup()
BuildException
- if problems were detected during the cleanup. If you
choose to trap this, be aware that you may get further errors downstream.public Cell pushHierarchy(CellInterface[] cell_interface, java.lang.String cellname)
cell_interface
- the cell_interface of the new subcellcellname
- the name of this type of cell
public Cell pushHierarchy(CellInterface[] cell_interface, java.lang.String cellname, boolean unique_structure)
cell_interface
- the cell_interface of the new subcellcellname
- the name of this type of cellunique_structure
- whether or not CellInterfaceDeterminesUniqueNetlistStructure
public Cell pushHierarchy(CellInterface[] cell_interface, java.lang.String cellname, java.lang.String instance_name)
cell_interface
- the cell_interface of the new subcellcellname
- the name of this type of cellinstance_name
- the name of this instance of the cell
public Cell pushHierarchy(CellInterface[] cell_interface, java.lang.String cellname, boolean unique_structure, java.lang.String instance_name)
popHierarchy()
. In this manner, a user can create multiple cells in a single
class file, and group related structure into coherent units. It also facilitates
creating multiple identical sub-blocks inside a loop or method. Each pushHierarchy
must be accompanied by a popHierarchy. Between the two calls, any Cell or Wire created
with the current class as the parent will actually be assigned to the subcell.
This version will copy the implicit_interface of the parent class; to avoid this, use
pushHierarchyNoImplicitPorts(CellInterface[], String, boolean, String)
.
cell_interface
- the cell_interface of the new subcellcellname
- the name of this type of cell (may not be null)unique_structure
- whether or not CellInterfaceDeterminesUniqueNetlistStructureinstance_name
- the name of this instance of the cell
BuildException
- if there is problem during the creation of the subcellpublic void popHierarchy()
#pushHierarchy()
.
public SubCell constructSubCell(Node parent, java.lang.String name)
pushHierarchy
.
The SubCell
interface should only be applied to an object that extends Cell.
When extending this, be sure to also extend getSubCellClass.
parent
- the parent of the subcellname
- the name of the subcell
public SubCell constructSubCellNoImplicitPorts(Node parent, java.lang.String name)
pushHierarchyNoImplicitPorts(CellInterface[], String, boolean, String)
.
The SubCell
interface should only be applied to an object that extends Cell.
When extending this, be sure to also extend getSubCellClass.
parent
- the parent of the subcellname
- the name of the subcell
public java.lang.Class getSubCellClass()
SubCell
.
DefaultSubCell
.public static final Wire nc(Wire w)
w
- the wire to mark as nc.
public boolean isAsynchronousSourceSinkResolved()
public void setAsynchronousSourceSinkResolved(boolean yes)
public abstract boolean hasBehaviorInPropagateMethod()
Propagateable#propagate()
method that is called
as part of the circuit's current behavioral model.
public abstract boolean hasBehaviorInClockMethod()
Clockable.clock()
and Clockable.reset()
method that are called as part of the circuit's current behavioral model.
public int userDefinedClockCount()
public final boolean isRoot()
HWSystem
for the root).
public CellList getDescendents()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |