byucc.jhdl.base
Class Wire

java.lang.Object
  extended by byucc.jhdl.base.Nameable
      extended by byucc.jhdl.base.Wire
All Implemented Interfaces:
Cloneable

public abstract class Wire
extends byucc.jhdl.base.Nameable
implements Cloneable

A base class for wires that communicate actual values in the system. Implements Cloneable to allow creation of aliases.

Author:
Brad Hutchings, Alan Feldstein

Constructor Summary
protected Wire(byucc.jhdl.base.Cell parent, int num_of_wires, int wire_width, String name)
          Deprecated. Use Wire(parent, num_of_wires, name).
protected Wire(byucc.jhdl.base.Cell parent, int num_of_wires, String name)
          Base constructor.
protected Wire(byucc.jhdl.base.Cell parent, String name)
          This creates a new Wire that is empty so that its contents can be filled in later.
protected Wire(byucc.jhdl.base.Cell parent, Wire[] wa, String name)
          This builds a wire from an array of wires that is passed in.
protected Wire(byucc.jhdl.base.Cell parent, byucc.jhdl.base.WireList wl, String name)
          Deprecated. Use Wire(Cell, Wire[], String), which has most significant bits in slot 0
 
Method Summary
 void addProperties(byucc.jhdl.base.Cell parent, byucc.jhdl.base.PropertyList plist)
          Used to add a list of properties to the Wire, within the scope of the given cell.
 void addProperties(byucc.jhdl.base.Cell parent, byucc.jhdl.base.PropertyList plist, boolean warn_duplicates)
          Used to add a list of properties to the Wire, withing the scope of the given cell.
 void addProperties(byucc.jhdl.base.PropertyList plist)
          Used to add a list of properties to the Wire, within the scope of the wire origin.
 void addProperties(byucc.jhdl.base.PropertyList plist, boolean warn_duplicates)
          Used to add a list of properties to the Wire, within the scope of the wire origin.
 void addProperty(byucc.jhdl.base.Cell parent, byucc.jhdl.base.Property p)
          Used to add a Property object to a Wire, within the scope of the given Cell.
 void addProperty(byucc.jhdl.base.Cell parent, String name, Object value, boolean isVisible)
           
 void addProperty(byucc.jhdl.base.Cell parent, String name, String value)
          Used to add a string property to a Wire, within the scope of the given Cell.
 void addProperty(byucc.jhdl.base.Property p)
          Deprecated. If you're using this addProperty, you're probably using it incorrectly. Use addProperty(Cell parent, String name, String value) instead to specify the scope of the property on this wire.
 void addProperty(String name, Object value, boolean isVisible)
           
 void addProperty(String name, String value)
          Deprecated. If you're using this addProperty, you're probably using it incorrectly. Use addProperty(Cell parent, String name, String value) instead to specify the scope of the property on this wire.
 void clearTransitionCount()
          Clears the transition count, if it is enabled.
 Wire createAlias()
          Creates an orphan wire alias of an existing wire.
 Wire createAlias(byucc.jhdl.base.Cell parent)
          This creates an alias of an existing wire.
 Wire createAlias(byucc.jhdl.base.Cell parent, String name)
          This creates an alias of an existing wire.
 Wire createAlias(String name)
          Creates an orphan wire alias of an existing wire.
 void delete()
          Removes a wire from a circuit.
 boolean equals(Object o)
          Allows comparison of wires based on the isAlias relation.
 void fixPutCounts()
          Ugly hack for simulation purposes
 int get(byucc.jhdl.base.Browser obj)
          This is provided so that a debugger will be able to freely access a wire.
 int get(byucc.jhdl.base.Cell sink)
          Values are read from wires using this method.
 int[] getA(byucc.jhdl.base.Browser obj)
          int[] version of get for browser.
 int[] getA(byucc.jhdl.base.Cell sink)
          int[] version of get.
 Wire getAliasForScope(byucc.jhdl.base.Cell parent)
          Returns an alias of the wire with the given scope.
 byucc.jhdl.base.CellList getAllSinkCells()
          This will find all unique cells that connected this wire (or an alias) to an in port.
 byucc.jhdl.base.CellList getAllSourceCells()
          This will find all unique cells that connected this wire (or an alias) to an out port.
abstract  int getAtomicWidth()
          Returns the atomic width of a wire.
 byucc.jhdl.base.WireList getAtomicWires()
          This blasts a wire into its atomic constituents.
 boolean getB(byucc.jhdl.base.Cell sink)
          Boolean version of get.
 boolean getB(byucc.jhdl.base.Cell sink, int i)
          Boolean version of get, for wires wider than 1 bit.
 byucc.jhdl.base.BV getBV(byucc.jhdl.base.Browser obj)
          BV version of get for browser.
 byucc.jhdl.base.BV getBV(byucc.jhdl.base.Browser obj, byucc.jhdl.base.BV bv)
          BV version of get for browser.
 byucc.jhdl.base.BV getBV(byucc.jhdl.base.Cell sink)
          BV version of get.
 byucc.jhdl.base.BV getBV(byucc.jhdl.base.Cell sink, byucc.jhdl.base.BV out)
          BV version of get.
 String getCanonicalName()
          This provides a canonical name for an atomic wire, one that can serve as a global wire name in a flat netlist.
 long getL(byucc.jhdl.base.Browser obj)
          Long version of get for browser.
 long getL(byucc.jhdl.base.Cell sink)
          Long version of get.
 long getL(byucc.jhdl.base.Cell sink, int upper_bound, int lower_bound)
          Long version of get, for reading the value of a range of bits.
 byucc.jhdl.base.CellList getLeafSinkCells()
          This will go down and find all of the unique, simulating leaf sink cells of this wire.
 byucc.jhdl.base.CellList getLeafSourceCells()
          This will go down and find all of the unique, simulating leaf source cells of this wire.
 double getLoad()
          Gets the load value, if it is enabled.
 byucc.jhdl.base.CellList getNetlistLeafSinkCellsNonUnique()
          This will find all leaf non-unique cells that connected this wire (or an alias) to an in port.
 Wire getOrigin()
          This returns the original wire that created the bits of this wire.
 byucc.jhdl.base.Node getParent()
          Simple accessor to get the parent of the wire.
 byucc.jhdl.base.Cell getParentCell()
          Simple accessor to get the parent of the wire, without casting
 byucc.jhdl.base.PropertyList getProperties()
          Used to get the property list from the wire, at the scope of the wire origin.
 byucc.jhdl.base.PropertyList getProperties(byucc.jhdl.base.Cell parent)
          Used to get the property list from the wire from the scope of the given cell.
 byucc.jhdl.base.Property getProperty(byucc.jhdl.base.Cell parent, String name)
           
 byucc.jhdl.base.Property getProperty(String name)
           
 Object getPropertyValue(byucc.jhdl.base.Cell parent, String name)
           
 Object getPropertyValue(String name)
           
 byucc.jhdl.base.Cell getSinkCell()
           
 byucc.jhdl.base.CellList getSinkCells()
          This will go down and find all of the unique, behaviorally modeled sink cells that have this wire as an input.
 byucc.jhdl.base.Cell getSourceCell()
           
 byucc.jhdl.base.CellList getSourceCells()
          This will go down and find all of the unique, behaviorally modeled source cells that can drive this wire.
 byucc.jhdl.base.HWSystem getSystem()
          Simple accessor to get to the system of this wire.
 int getTransitionCount()
          Returns the number of times this wire has had transitions, if counting is enabled.
 byucc.jhdl.base.ValuePropagater[] getValueArray()
          Just allows direct access to the contained value propagater array.
 int getWidth()
          Returns the declared width of the wire in bits.
 Wire getWire(byucc.jhdl.base.Cell parent, int i)
          This returns the ith atomic wire.
 Wire getWire(byucc.jhdl.base.Cell parent, int i, String name)
          This returns the ith atomic wire.
 Wire getWire(int i)
          This returns the ith atomic wire.
 Wire getWire(int i, String name)
          This returns the ith atomic wire.
 int getX(byucc.jhdl.base.Browser obj)
          This is provided so that a debugger will be able to freely access a wire.
 int getX(byucc.jhdl.base.Cell sink)
          Mask of multiple puts are from wires using this method.
 int[] getXA(byucc.jhdl.base.Cell sink)
           
 boolean getXB(byucc.jhdl.base.Cell sink)
          Boolean version of getX.
 byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Browser obj)
          BV version of getX for browser.
 byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Browser obj, byucc.jhdl.base.BV bv)
          BV version of get for browser.
 byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Cell sink)
          BV version of getX.
 byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Cell sink, byucc.jhdl.base.BV out)
          BV version of getX.
 long getXL(byucc.jhdl.base.Browser obj)
          Long version of getX for browser.
 long getXL(byucc.jhdl.base.Cell sink)
          Long version of getX.
 int getZ(byucc.jhdl.base.Browser obj)
          This is provided so that a debugger will be able to freely access a wire.
 int getZ(byucc.jhdl.base.Cell sink)
          Mask of floating values are from wires using this method.
 int[] getZA(byucc.jhdl.base.Cell sink)
           
 boolean getZB(byucc.jhdl.base.Cell sink)
          Boolean version of getZ.
 byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Browser obj)
          BV version of getZ for browser.
 byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Browser obj, byucc.jhdl.base.BV bv)
          BV version of get for browser.
 byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Cell sink)
          BV version of getZ.
 byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Cell sink, byucc.jhdl.base.BV out)
          BV version of getZ.
 long getZL(byucc.jhdl.base.Browser obj)
          Long version of getZ for browser.
 long getZL(byucc.jhdl.base.Cell sink)
          Long version of getZ.
 Wire gw(byucc.jhdl.base.Cell parent, int i)
          Shorthand for getWire(Cell, int).
 Wire gw(byucc.jhdl.base.Cell parent, int i, String name)
          Shorthand for getWire(Cell, int, String).
 Wire gw(int i)
          Shorthand for getWire(int).
 Wire gw(int i, String name)
          Shorthand for getWire(int, String).
 boolean hasBeenPut()
           
 int hashCode()
          Allows hashing of wires based on the isAlias relation.
 boolean hasProperties()
          Used to determine if this wire has properties.
 boolean hasProperties(byucc.jhdl.base.Cell parent)
          Used to determine if this wire has properties, at the scope of the given cell.
protected  void init(int num_of_wires)
          In some cases the derived class may to perform some checking on the arguments before invoking the superclass constructor.
protected  void init(int num_of_wires, int wire_width)
          Deprecated. Use init(num_of_wires).
protected  void initWireFromArray(Wire[] wa)
          This builds a wire from an array of wires that is passed in.
protected  void initWireFromList(byucc.jhdl.base.WireList wl)
          Deprecated. Use initWireFromArray(Wire[]) instead, which takes most significant bit in slot 0
 void initWireFromRange(Wire new_wire, Wire original, int upper_bound, int lower_bound)
          Deprecated. For access to a wire range, use range or variant.
 boolean isAlias(Wire w)
          Allows you to check if one wire is an alias for another.
 boolean isAlreadySourced()
          Used to check to see if a wire has already been sourced by someone else.
 boolean isAtomic()
          Checks to see if a wire is atomic
 boolean isBidirectional()
          Deprecated. No longer used.
 void isOkToDangle(boolean flag)
          This will enable/disable any warning messages about this wire if it dangles.
 boolean isRoot()
          This has to be defined so satisfy Nameable as it needs to know whether the Nameable thing it is currently looking at is the root or not.
 boolean isSourcelessOk()
          This returns the status of whether it is allowable for the wire to have no source, a necessary condition to being an NC wire.
 int isSubsetOf(Wire w)
          Checks to see if the bound instance wire is contained within the parameter.
 boolean isUnidirectional()
          Deprecated. No longer used.
protected  Wire newWire(byucc.jhdl.base.Cell parent, String name)
          This creates an alias of this wire, using the clone mechanism.
protected  boolean orphanAllowed()
          Wire can be orphan although about the only thing you can do with an orphan wire is pass it into a port or use it to create new wires which themselves may or may not be orphans.
 void put(byucc.jhdl.base.Cell source, int val)
          Values are placed on a wire using this method.
 void putA(byucc.jhdl.base.Cell source, int[] val)
          int[] version of put.
 void putB(byucc.jhdl.base.Cell source, boolean val)
          Boolean version of put.
 void putB(byucc.jhdl.base.Cell source, boolean val, int i)
          Boolean version of put, for wires wider than 1 bit.
 void putBV(byucc.jhdl.base.Cell source, byucc.jhdl.base.BV val)
          Values are placed on a wire using this method.
 void putL(byucc.jhdl.base.Cell source, long val)
          Long version of put.
 void putL(byucc.jhdl.base.Cell source, long val, int upper_bound, int lower_bound)
          Long version of put, for affecting a range of bits.
 void putTriState(byucc.jhdl.base.Cell source, int val)
          Values are placed on a wire using this method.
 void putTriStateA(byucc.jhdl.base.Cell source, int[] val)
          int[] version of putTriState.
 void putTriStateBV(byucc.jhdl.base.Cell source, byucc.jhdl.base.BV val)
          BV version of putTriState.
 void putTriStateL(byucc.jhdl.base.Cell source, long val)
          Long version of putTriState.
 Wire range(byucc.jhdl.base.Cell parent, int upper_bound, int lower_bound)
          This returns a new wire that contains only the prescribed range.
 Wire range(byucc.jhdl.base.Cell parent, int upper_bound, int lower_bound, String name)
          This returns a new wire that contains only the prescribed range in BITS.
 Wire range(int upper_bound, int lower_bound)
          This returns a new wire that contains only the prescribed range.
 Wire range(int upper_bound, int lower_bound, String name)
          This returns a new wire that contains only the prescribed range.
 boolean removeProperty(byucc.jhdl.base.Cell parent, String name)
          Used to remove a named property of a Wire at the scope of the given cell.
 boolean removeProperty(String name)
          Used to remove a named property of a Wire at the scope of the wire origin.
 void replaceProperty(byucc.jhdl.base.Cell parent, byucc.jhdl.base.Property p)
          Used to replace a property of a Wire.
 void replaceProperty(byucc.jhdl.base.Cell parent, String name, String value)
          Used to replace a string property of a Wire.
 void replaceProperty(byucc.jhdl.base.Property p)
          Used to replace a property of a Wire, within the scope of the wire origin.
 void replaceProperty(String name, String value)
          Used to replace a string property of a Wire, within the scope of the wire origin.
 void setLoad(double load)
          Sets the load value, if it is enabled.
 byucc.jhdl.base.Property setProperty(byucc.jhdl.base.Cell parent, String name, Object value, boolean isVisible)
           
 byucc.jhdl.base.Property setProperty(String name, Object value, boolean isVisible)
           
 boolean statisticsEnabled()
           
 String toString()
          Outputs the full name of this wire.
protected  boolean validSinkCell(byucc.jhdl.base.Cell sink)
          Checks to see if sink is allowed to get values from this wire.
protected  boolean validSourceCell(byucc.jhdl.base.Cell source)
          Checks to see if source is allowed to put values onto this wire.
 
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, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Wire

protected Wire(byucc.jhdl.base.Cell parent,
               String name)
This creates a new Wire that is empty so that its contents can be filled in later. It does initialize the name and parent slots.

Parameters:
parent - the parent of this wire.
name - the name of this wire.

Wire

protected Wire(byucc.jhdl.base.Cell parent,
               int num_of_wires,
               int wire_width,
               String name)
Deprecated. Use Wire(parent, num_of_wires, name).

Base constructor. Requires the parent and a name. The main interface for creating a Wire is this constructor. It requires that you state how many wires and the width of each wire. When you derive this class, the constructor can just take a width argument and then handle the num_of_wires and wire_width (this is the width of each wire to be created).

Parameters:
parent - the parent (the owner) of this wire.
num_of_wires - the num of wires in this wire.
wire_width - the width of each of the wires.
name - the user-specified name.

Wire

protected Wire(byucc.jhdl.base.Cell parent,
               int num_of_wires,
               String name)
Base constructor. Requires the parent and a name. The main interface for creating a Wire is this constructor. It requires that you state how many atomic wires (NOT bits) to build, reading getAtomicWidth() for the wire sizes.

Parameters:
parent - the parent (the owner) of this wire.
num_of_wires - the num of atomic wires (NOT bits) in this wire.
name - the user-specified name.

Wire

protected Wire(byucc.jhdl.base.Cell parent,
               byucc.jhdl.base.WireList wl,
               String name)
Deprecated. Use Wire(Cell, Wire[], String), which has most significant bits in slot 0

This builds a wire from a list of wires that is passed in. This method is provided mainly to help the library writer so he can support a variety of interfaces for constructing wires.

As an example, with foo and bar each 3 bit wires and pie a two bit wire, this sequence of code (if Wire were not abstract):

WireList mylist = new WireList();
  mylist.insert(foo);
  mylist.insert(bar);
  mylist.insert(pie);
  Wire mywire = new Wire(parent, mylist, name);

would make mywire contain the following bits, starting from the most significant: foo[2], foo[1], foo[0], bar[2], bar[1], bar[0], pie[1], pie[0].

Parameters:
parent - the parent of this wire.
wl - the list of wires that will be placed in this wire, least significant slots at list head
name - the name of this wire.

Wire

protected Wire(byucc.jhdl.base.Cell parent,
               Wire[] wa,
               String name)
This builds a wire from an array of wires that is passed in. This method is provided mainly to help the library writer so he can support a variety of interfaces for constructing wires.

As an example, with foo and bar each 3 bit wires and pie a two bit wire, this sequence of code (if Wire were not abstract):

Wire[] myarray = new Wire[] { foo, bar, pie };
  Wire mywire = new Wire(parent, myarray, name);

would make mywire contain the following bits, starting from the most significant: foo[2], foo[1], foo[0], bar[2], bar[1], bar[0], pie[1], pie[0].

Parameters:
parent - the parent of this wire.
wa - the array of wires that will be placed in this wire, most significant bits in slot 0
name - the name of this wire.
Method Detail

getAtomicWidth

public abstract int getAtomicWidth()
Returns the atomic width of a wire. Valid widths are 1, 2, 4, and 8.

Returns:
the minimum width of a wire for the current architecture.

getSystem

public byucc.jhdl.base.HWSystem getSystem()
Simple accessor to get to the system of this wire.

Returns:
the HWSystem this wire belongs to.

init

protected void init(int num_of_wires,
                    int wire_width)
Deprecated. Use init(num_of_wires).

In some cases the derived class may to perform some checking on the arguments before invoking the superclass constructor. This init allows you to perform initialization through a method instead of a constructor.


init

protected void init(int num_of_wires)
In some cases the derived class may to perform some checking on the arguments before invoking the superclass constructor. This init allows you to perform initialization through a method instead of a constructor.

Parameters:
num_of_wires - the number of atomic wires (NOT bits) to include in this wire

initWireFromList

protected void initWireFromList(byucc.jhdl.base.WireList wl)
Deprecated. Use initWireFromArray(Wire[]) instead, which takes most significant bit in slot 0

This builds a wire from a list of wires that is passed in. This method is provided mainly to help the library writer so he can support a variety of interfaces for constructing wires. It would be nice for this to be a constructor, however, I need to allow for the list to be constructed before this method was called. Note that the base constructor must be called before this method is invoked. The least significant bit of the new wire is taken from the first element of the list.

Parameters:
wl - the list of wires that will be placed in this wire, least significant bits at list head

initWireFromArray

protected void initWireFromArray(Wire[] wa)
This builds a wire from an array of wires that is passed in. This method is provided mainly to help the library writer so he can support a variety of interfaces for constructing wires. It would be nice for this to be a constructor, however, I need to allow for the array to be constructed before this method was called. Note that the base constructor must be called before this method is invoked. The most significant bit of the new wire is taken from the first slot of the array.

Parameters:
wa - the list of wires that will be placed in this wire, most significant bits in slot 0

getParent

public final byucc.jhdl.base.Node getParent()
Simple accessor to get the parent of the wire. This must return a Node because it redefines a Nameable method. (Wouldn't it be nice if Java had covariant return types!) It will always be a Cell because that is the only thing that setParent will take.

Specified by:
getParent in class byucc.jhdl.base.Nameable
Returns:
the parent of this wire.
See Also:
getParentCell()

getParentCell

public final byucc.jhdl.base.Cell getParentCell()
Simple accessor to get the parent of the wire, without casting

Returns:
the parent of this wire.

getValueArray

public byucc.jhdl.base.ValuePropagater[] getValueArray()
Just allows direct access to the contained value propagater array.

Returns:
the value propagaters that make up this wire.

statisticsEnabled

public boolean statisticsEnabled()

initWireFromRange

public void initWireFromRange(Wire new_wire,
                              Wire original,
                              int upper_bound,
                              int lower_bound)
Deprecated. For access to a wire range, use range or variant.

Provided for derived classes to setup the value propagaters. It constructs a new value propagater array based on the range and the array that was passed in. Note that the range is inclusive.

Parameters:
new_wire - the wire that will get the range.
original - the wire that is being range()d.
upper_bound - the upper bound of the range.
lower_bound - the lower bound of the range.

toString

public String toString()
Outputs the full name of this wire.

Overrides:
toString in class Object
Returns:
the name of this wire.

getSinkCell

public byucc.jhdl.base.Cell getSinkCell()
Returns:
the first sink cell of this wire
Since:
Oct 10, 2000 API Change - returns the first simulating sink cell off this wire.
See Also:
getSinkCells()

getSourceCell

public byucc.jhdl.base.Cell getSourceCell()
Returns:
the first source cell of this wire
Since:
Oct 10, 2000 API Change - returns the first simulating source cell on this wire.
See Also:
getSourceCells()

getSinkCells

public byucc.jhdl.base.CellList getSinkCells()
This will go down and find all of the unique, behaviorally modeled sink cells that have this wire as an input.

Returns:
a list of all of the SIMULATING sink cells hanging off this wire.
See Also:
getAllSinkCells()

getNetlistLeafSinkCellsNonUnique

public byucc.jhdl.base.CellList getNetlistLeafSinkCellsNonUnique()
This will find all leaf non-unique cells that connected this wire (or an alias) to an in port. or more (for each cell it connects to).

Returns:
a list of all sink cells hanging off this wire.

getAllSinkCells

public byucc.jhdl.base.CellList getAllSinkCells()
This will find all unique cells that connected this wire (or an alias) to an in port.

Returns:
a list of all sink cells hanging off this wire.

getLeafSinkCells

public byucc.jhdl.base.CellList getLeafSinkCells()
This will go down and find all of the unique, simulating leaf sink cells of this wire.

Returns:
a list of all of the SIMULATING leaf sink cells hanging off this wire.

getSourceCells

public byucc.jhdl.base.CellList getSourceCells()
This will go down and find all of the unique, behaviorally modeled source cells that can drive this wire.

Returns:
a list of all of the SIMULATING source cells hanging off this wire.

getAllSourceCells

public byucc.jhdl.base.CellList getAllSourceCells()
This will find all unique cells that connected this wire (or an alias) to an out port.

Returns:
a list of all source cells hanging off this wire.

getLeafSourceCells

public byucc.jhdl.base.CellList getLeafSourceCells()
This will go down and find all of the unique, simulating leaf source cells of this wire.

Returns:
a list of all of the SIMULATING leaf source cells hanging off this wire.

isUnidirectional

public boolean isUnidirectional()
Deprecated. No longer used.

No longer used.

Returns:
true.

isBidirectional

public final boolean isBidirectional()
Deprecated. No longer used.

No longer used.

Returns:
false.

put

public void put(byucc.jhdl.base.Cell source,
                int val)
Values are placed on a wire using this method.

Parameters:
source - the source node driving the wire.
val - the value being driven (int).

putB

public void putB(byucc.jhdl.base.Cell source,
                 boolean val)
Boolean version of put.

Parameters:
source - the source node driving the wire.
val - the value being driven (boolean).

putB

public void putB(byucc.jhdl.base.Cell source,
                 boolean val,
                 int i)
          throws byucc.jhdl.base.PutGetException,
                 ArrayIndexOutOfBoundsException,
                 byucc.jhdl.base.WireSizeException,
                 IllegalArgumentException
Boolean version of put, for wires wider than 1 bit.

Parameters:
source - the source node driving the wire.
val - the value being driven (boolean).
i - the index of the atomic wire you are requesting.
Throws:
byucc.jhdl.base.PutGetException
ArrayIndexOutOfBoundsException
byucc.jhdl.base.WireSizeException
IllegalArgumentException

putBV

public void putBV(byucc.jhdl.base.Cell source,
                  byucc.jhdl.base.BV val)
Values are placed on a wire using this method.

Parameters:
source - the source node driving the wire.
val - the value being driven (BV).

putL

public void putL(byucc.jhdl.base.Cell source,
                 long val)
Long version of put.

Parameters:
source - the source node driving the wire.
val - the value being driven (long).

putL

public void putL(byucc.jhdl.base.Cell source,
                 long val,
                 int upper_bound,
                 int lower_bound)
          throws byucc.jhdl.base.PutGetException,
                 ArrayIndexOutOfBoundsException,
                 byucc.jhdl.base.WireSizeException,
                 IllegalArgumentException
Long version of put, for affecting a range of bits.

Parameters:
source - the source node driving the wire.
val - the value being driven (long).
upper_bound - the upper bound of the range IN BITS.
lower_bound - the upper bound of the range IN BITS.
Throws:
byucc.jhdl.base.PutGetException
ArrayIndexOutOfBoundsException
byucc.jhdl.base.WireSizeException
IllegalArgumentException

putA

public void putA(byucc.jhdl.base.Cell source,
                 int[] val)
int[] version of put.

Parameters:
source - the source node driving the wire.
val - the value being driven (int[]).

putTriState

public void putTriState(byucc.jhdl.base.Cell source,
                        int val)
Values are placed on a wire using this method.

Parameters:
source - the source node driving the wire.
val - the value being driven (int).

putTriStateBV

public void putTriStateBV(byucc.jhdl.base.Cell source,
                          byucc.jhdl.base.BV val)
BV version of putTriState.

Parameters:
source - the source node driving the wire.
val - the value being driven (BV).

putTriStateL

public void putTriStateL(byucc.jhdl.base.Cell source,
                         long val)
Long version of putTriState.

Parameters:
source - the source node driving the wire.
val - the value being driven (long).

putTriStateA

public void putTriStateA(byucc.jhdl.base.Cell source,
                         int[] val)
int[] version of putTriState.

Parameters:
source - the source node driving the wire.
val - the value being driven (int[]).

get

public int get(byucc.jhdl.base.Cell sink)
Values are read from wires using this method.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (int).

getZ

public int getZ(byucc.jhdl.base.Cell sink)
Mask of floating values are from wires using this method.

Parameters:
sink - the sink node reading the value.
Returns:
where any bit that is one corresponds to a floating value in get().

getX

public int getX(byucc.jhdl.base.Cell sink)
Mask of multiple puts are from wires using this method.

Parameters:
sink - the sink node reading the value.
Returns:
where any bit that is one corresponds to a floating value in get().

getB

public boolean getB(byucc.jhdl.base.Cell sink)
Boolean version of get.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (boolean).

getB

public boolean getB(byucc.jhdl.base.Cell sink,
                    int i)
             throws byucc.jhdl.base.PutGetException,
                    ArrayIndexOutOfBoundsException,
                    byucc.jhdl.base.WireSizeException,
                    IllegalArgumentException
Boolean version of get, for wires wider than 1 bit.

Parameters:
sink - the sink node reading the value.
i - the index of the atomic wire you are requesting.
Returns:
the value currently driven onto the wire (boolean).
Throws:
byucc.jhdl.base.PutGetException
ArrayIndexOutOfBoundsException
byucc.jhdl.base.WireSizeException
IllegalArgumentException

getZB

public boolean getZB(byucc.jhdl.base.Cell sink)
Boolean version of getZ.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (boolean).

getXB

public boolean getXB(byucc.jhdl.base.Cell sink)
Boolean version of getX.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (boolean).

getBV

public byucc.jhdl.base.BV getBV(byucc.jhdl.base.Cell sink)
BV version of get.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (BV).

getZBV

public byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Cell sink)
BV version of getZ.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (BV).

getXBV

public byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Cell sink)
BV version of getX.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (BV).

getBV

public byucc.jhdl.base.BV getBV(byucc.jhdl.base.Cell sink,
                                byucc.jhdl.base.BV out)
BV version of get.

Parameters:
sink - the sink node reading the value.
out - the BV to place the output on.
Returns:
the value currently driven onto the wire (BV).

getZBV

public byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Cell sink,
                                 byucc.jhdl.base.BV out)
BV version of getZ.

Parameters:
sink - the sink node reading the value.
out - the BV to place the output on.
Returns:
the value currently driven onto the wire (BV).

getXBV

public byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Cell sink,
                                 byucc.jhdl.base.BV out)
BV version of getX.

Parameters:
sink - the sink node reading the value.
out - the BV to place the output on.
Returns:
the value currently driven onto the wire (BV).

getL

public long getL(byucc.jhdl.base.Cell sink)
Long version of get.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (long).

getL

public long getL(byucc.jhdl.base.Cell sink,
                 int upper_bound,
                 int lower_bound)
          throws byucc.jhdl.base.PutGetException,
                 ArrayIndexOutOfBoundsException,
                 byucc.jhdl.base.WireSizeException,
                 IllegalArgumentException
Long version of get, for reading the value of a range of bits.

Parameters:
sink - the sink node reading the value.
upper_bound - the upper bound of the range IN BITS.
lower_bound - the upper bound of the range IN BITS.
Returns:
the value currently driven onto the wire (long).
Throws:
byucc.jhdl.base.PutGetException
ArrayIndexOutOfBoundsException
byucc.jhdl.base.WireSizeException
IllegalArgumentException

getZL

public long getZL(byucc.jhdl.base.Cell sink)
Long version of getZ.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (long).

getXL

public long getXL(byucc.jhdl.base.Cell sink)
Long version of getX.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (long).

getA

public int[] getA(byucc.jhdl.base.Cell sink)
int[] version of get.

Parameters:
sink - the sink node reading the value.
Returns:
the value currently driven onto the wire (int[]).

getZA

public int[] getZA(byucc.jhdl.base.Cell sink)

getXA

public int[] getXA(byucc.jhdl.base.Cell sink)

getZ

public int getZ(byucc.jhdl.base.Browser obj)
         throws byucc.jhdl.base.WireValueException
This is provided so that a debugger will be able to freely access a wire. This should return the current value of the wire without the need to check whether the object is a valid sink node.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getX

public int getX(byucc.jhdl.base.Browser obj)
         throws byucc.jhdl.base.WireValueException
This is provided so that a debugger will be able to freely access a wire. This should return the current value of the wire without the need to check whether the object is a valid sink node.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

get

public int get(byucc.jhdl.base.Browser obj)
        throws byucc.jhdl.base.WireValueException
This is provided so that a debugger will be able to freely access a wire. This should return the current value of the wire without the need to check whether the object is a valid sink node.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getL

public long getL(byucc.jhdl.base.Browser obj)
          throws byucc.jhdl.base.WireValueException
Long version of get for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getZL

public long getZL(byucc.jhdl.base.Browser obj)
           throws byucc.jhdl.base.WireValueException
Long version of getZ for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getXL

public long getXL(byucc.jhdl.base.Browser obj)
           throws byucc.jhdl.base.WireValueException
Long version of getX for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getA

public int[] getA(byucc.jhdl.base.Browser obj)
           throws byucc.jhdl.base.WireValueException
int[] version of get for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getBV

public byucc.jhdl.base.BV getBV(byucc.jhdl.base.Browser obj)
                         throws byucc.jhdl.base.WireValueException
BV version of get for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getBV

public byucc.jhdl.base.BV getBV(byucc.jhdl.base.Browser obj,
                                byucc.jhdl.base.BV bv)
                         throws byucc.jhdl.base.WireValueException
BV version of get for browser.

Parameters:
obj - the browser object seeking access.
bv - the BV to place the result onto
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getZBV

public byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Browser obj)
                          throws byucc.jhdl.base.WireValueException
BV version of getZ for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getZBV

public byucc.jhdl.base.BV getZBV(byucc.jhdl.base.Browser obj,
                                 byucc.jhdl.base.BV bv)
                          throws byucc.jhdl.base.WireValueException
BV version of get for browser.

Parameters:
obj - the browser object seeking access.
bv - the BV to place the result onto
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getXBV

public byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Browser obj)
                          throws byucc.jhdl.base.WireValueException
BV version of getX for browser.

Parameters:
obj - the browser object seeking access.
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getXBV

public byucc.jhdl.base.BV getXBV(byucc.jhdl.base.Browser obj,
                                 byucc.jhdl.base.BV bv)
                          throws byucc.jhdl.base.WireValueException
BV version of get for browser.

Parameters:
obj - the browser object seeking access.
bv - the BV to place the result onto
Returns:
the value currently driven onto the wire.
Throws:
WireValueException - if the wire had an invalid value

getWidth

public final int getWidth()
Returns the declared width of the wire in bits.

Returns:
the declared width of the wire, or 0 if this wire is not initialized or was deleted

validSourceCell

protected final boolean validSourceCell(byucc.jhdl.base.Cell source)
Checks to see if source is allowed to put values onto this wire. A cell can put only if the cell is the parent and the access control has been set to write.

Parameters:
source - the source cell being checked.
Returns:
true if a put is allowed, false otherwise.

validSinkCell

protected final boolean validSinkCell(byucc.jhdl.base.Cell sink)
Checks to see if sink is allowed to get values from this wire.

Parameters:
sink - the sink cell being checked.
Returns:
true if a get is allowed, false otherwise.

createAlias

public final Wire createAlias(byucc.jhdl.base.Cell parent,
                              String name)
This creates an alias of an existing wire. The name can be set to anything you like and the parent has to be whomever is locally referring to the alias. This is so that hierarchical naming can be supported and also so that the parent can be quickly checked for either legal puts or gets from the wire.

Parameters:
parent - the new parent for this alias.
name - the name of the alias.
Returns:
the alias just created

createAlias

public final Wire createAlias(String name)
Creates an orphan wire alias of an existing wire. The new wire has no parent cell, so it is limited in features unless it is passed to a connect call to be given a parent cell.

Parameters:
name - the name of the alias.
Returns:
the alias just created

createAlias

public final Wire createAlias(byucc.jhdl.base.Cell parent)
This creates an alias of an existing wire. The alias is unnamed.

Parameters:
parent - the new parent for this alias.
Returns:
the alias just created

createAlias

public final Wire createAlias()
Creates an orphan wire alias of an existing wire. The new wire has no parent cell, so it is limited in features unless it is passed to a connect call to be given a parent cell.

Returns:
the alias just created

range

public Wire range(byucc.jhdl.base.Cell parent,
                  int upper_bound,
                  int lower_bound,
                  String name)
This returns a new wire that contains only the prescribed range in BITS. This checks that the range is a valid BIT (not atomic wire) range from the wire according to getAtomicWidth. To grab atomic wires, use getWire(parent, i, name) or variant. The bounds must be on atomic boundaries, within the width of the wire.

Parameters:
parent - the parent of the new wire.
upper_bound - the upper bound of the range IN BITS.
lower_bound - the lower bound of the range IN BITS.
name - the name of the new wire.
Returns:
the wire containing the specified range.

range

public Wire range(byucc.jhdl.base.Cell parent,
                  int upper_bound,
                  int lower_bound)
This returns a new wire that contains only the prescribed range.

Parameters:
parent - the parent of the new wire.
upper_bound - the upper bound of the range IN BITS.
lower_bound - the lower bound of the range IN BITS.
Returns:
the wire containing the specified range.
See Also:
range(Cell, int, int, String)

range

public Wire range(int upper_bound,
                  int lower_bound)
This returns a new wire that contains only the prescribed range. This is an anonymous version that does not have a parent.

Parameters:
upper_bound - the upper bound of the range IN BITS.
lower_bound - the lower bound of the range IN BITS.
Returns:
the wire containing the specified range.
See Also:
range(Cell, int, int, String)

range

public Wire range(int upper_bound,
                  int lower_bound,
                  String name)
This returns a new wire that contains only the prescribed range. This receives the parent of the wire it is ranging.

Parameters:
upper_bound - the upper bound of the range IN BITS.
lower_bound - the lower bound of the range IN BITS.
name - the name of the range.
Returns:
the wire containing the specified range.
See Also:
range(Cell, int, int, String)

newWire

protected final Wire newWire(byucc.jhdl.base.Cell parent,
                             String name)
This creates an alias of this wire, using the clone mechanism. The new wire has the specified parent and name; if name is null and the original wire had a user name, the user name is used.

Parameters:
parent - the parent of the new wire.
name - the name of the new wire.
Returns:
the newly constructed wire.

getWire

public final Wire getWire(int i)
This returns the ith atomic wire. Note that this returns an orphan wire that you can only alias.

Parameters:
i - the index of the atomic wire you are requesting.
Returns:
the atomic wire at the index.
See Also:
getWire(Cell, int, String)

getWire

public final Wire getWire(byucc.jhdl.base.Cell parent,
                          int i)
This returns the ith atomic wire. Note that this returns a wire with the specified parent.

Parameters:
parent - the parent you desire for the new wire.
i - the index of the atomic wire you are requesting.
Returns:
the atomic wire at the index.
See Also:
getWire(Cell, int, String)

getWire

public final Wire getWire(int i,
                          String name)
This returns the ith atomic wire. If the original wire has a parent, then the atomic wire will be named and have the same parent.

Parameters:
i - the index of the atomic wire you are requesting.
name - the name of the new wire (provided it has a parent).
Returns:
the atomic wire at the index.
See Also:
getWire(Cell, int, String)

getWire

public final Wire getWire(byucc.jhdl.base.Cell parent,
                          int i,
                          String name)
This returns the ith atomic wire. Note that this returns a wire with the specified parent. Really just syntactic sugar for range(parent, i, i, name) when atomic wire width is 1, but unique for larger atomic widths.

Parameters:
parent - the parent of the new wire.
i - the index of the atomic wire you are requesting.
name - the name of the new wire.
Returns:
the atomic wire at the index.

gw

public final Wire gw(int i)
Shorthand for getWire(int).

Parameters:
i - the index of the atomic wire you are requesting.
Returns:
the atomic wire at the index.
See Also:
getWire(int)

gw

public final Wire gw(byucc.jhdl.base.Cell parent,
                     int i)
Shorthand for getWire(Cell, int).

Parameters:
parent - the parent of the new wire.
i - the index of the atomic wire you are requesting.
Returns:
the atomic wire at the index.
See Also:
getWire(Cell, int)

gw

public final Wire gw(int i,
                     String name)
Shorthand for getWire(int, String).

Parameters:
i - the index of the atomic wire you are requesting.
name - the name of the new wire.
Returns:
the atomic wire at the index.
See Also:
getWire(int, String)

gw

public final Wire gw(byucc.jhdl.base.Cell parent,
                     int i,
                     String name)
Shorthand for getWire(Cell, int, String).

Parameters:
parent - the parent of the new wire.
i - the index of the atomic wire you are requesting.
name - the name of the new wire.
Returns:
the atomic wire at the index.
See Also:
getWire(Cell, int, String)

isRoot

public final boolean isRoot()
This has to be defined so satisfy Nameable as it needs to know whether the Nameable thing it is currently looking at is the root or not. Wires can never be the root, or anyone's parent, so this should never called. If it does, it returns false in any case.

Specified by:
isRoot in class byucc.jhdl.base.Nameable
Returns:
always returns false.

orphanAllowed

protected boolean orphanAllowed()
Wire can be orphan although about the only thing you can do with an orphan wire is pass it into a port or use it to create new wires which themselves may or may not be orphans.

Specified by:
orphanAllowed in class byucc.jhdl.base.Nameable
Returns:
true as this is allowed for the base class although this may be overridden in a derived class.

isAlreadySourced

public boolean isAlreadySourced()
Used to check to see if a wire has already been sourced by someone else.

Returns:
true if the wire is already sourced, false otherwise.

isAlias

public boolean isAlias(Wire w)
Allows you to check if one wire is an alias for another.

Parameters:
w - the wire you are checking for aliasing.
Returns:
true if w and the bound instance are aliases of each other, false otherwise.

equals

public boolean equals(Object o)
Allows comparison of wires based on the isAlias relation.

Overrides:
equals in class Object
Parameters:
o - the object to check for equality
Returns:
true if this wire and the compared wire contain the same atomic data, ie. they are aliases

hashCode

public int hashCode()
Allows hashing of wires based on the isAlias relation.

Overrides:
hashCode in class Object
Returns:
an integer that will be the same for two wires that satisfy equals()

isSubsetOf

public int isSubsetOf(Wire w)
Checks to see if the bound instance wire is contained within the parameter.

Parameters:
w - the bound instance is checked to see if it is a subset of w.
Returns:
-1 if the bound instance is not a subset of w, or the offset into the wire if it is a subset.

isAtomic

public boolean isAtomic()
Checks to see if a wire is atomic

Returns:
true if the width of the wire is the same as the atomic width of the wire.

getCanonicalName

public String getCanonicalName()
This provides a canonical name for an atomic wire, one that can serve as a global wire name in a flat netlist. This only works if the wire is atomic. It is a name that is based on the first constructor of the wire.

Returns:
the canonical name for the wire.
Throws:
BuildException - if the wire is not atomic.

getAtomicWires

public byucc.jhdl.base.WireList getAtomicWires()
This blasts a wire into its atomic constituents. Handy for netlisting. The list is low-endian--the lsb atomic wire is first on the return list.

Returns:
a wirelist with all of the atomic constituents for a wire.

isOkToDangle

public void isOkToDangle(boolean flag)
This will enable/disable any warning messages about this wire if it dangles. A dangling wire is a wire with either no sources or sinks, or only sources.

Parameters:
flag - the value to set the flag

isSourcelessOk

public boolean isSourcelessOk()
This returns the status of whether it is allowable for the wire to have no source, a necessary condition to being an NC wire.

Returns:
true if this wire was created by a call to nc.

getTransitionCount

public int getTransitionCount()
Returns the number of times this wire has had transitions, if counting is enabled.

Returns:
the transition count
See Also:
HWSystem.collectTransitionCountEnabled()

clearTransitionCount

public void clearTransitionCount()
Clears the transition count, if it is enabled.

See Also:
HWSystem.collectTransitionCountEnabled()

setLoad

public void setLoad(double load)
Sets the load value, if it is enabled.

See Also:
HWSystem.collectTransitionCountEnabled()

getLoad

public double getLoad()
Gets the load value, if it is enabled.

See Also:
HWSystem.collectTransitionCountEnabled()

fixPutCounts

public void fixPutCounts()
Ugly hack for simulation purposes


delete

public void delete()
Removes a wire from a circuit. Don't try to reference this wire after deleting it.

Specified by:
delete in class byucc.jhdl.base.Nameable

getAliasForScope

public Wire getAliasForScope(byucc.jhdl.base.Cell parent)
Returns an alias of the wire with the given scope.

Parameters:
parent - the parent cell for the scope

addProperty

public void addProperty(byucc.jhdl.base.Cell parent,
                        String name,
                        String value)
Used to add a string property to a Wire, within the scope of the given Cell. If necessary, an alias is created within the scope of the cell, so that the property will show up in a netlist only at the requested scope.

Parameters:
parent - the cell that defines the scope of the property.
name - the name of the property.
value - the string value of the property.

addProperty

public void addProperty(String name,
                        Object value,
                        boolean isVisible)

setProperty

public byucc.jhdl.base.Property setProperty(String name,
                                            Object value,
                                            boolean isVisible)

addProperty

public void addProperty(byucc.jhdl.base.Cell parent,
                        String name,
                        Object value,
                        boolean isVisible)

setProperty

public byucc.jhdl.base.Property setProperty(byucc.jhdl.base.Cell parent,
                                            String name,
                                            Object value,
                                            boolean isVisible)

addProperty

public void addProperty(byucc.jhdl.base.Cell parent,
                        byucc.jhdl.base.Property p)
Used to add a Property object to a Wire, within the scope of the given Cell. If necessary, an alias is created within the scope of the cell, so that the property will show up in a netlist only at the requested scope.

Parameters:
parent - the cell that defines the scope of the property.
p - the property object.

addProperty

public void addProperty(String name,
                        String value)
Deprecated. If you're using this addProperty, you're probably using it incorrectly. Use addProperty(Cell parent, String name, String value) instead to specify the scope of the property on this wire.

Used to add a string property to a Wire, at the scope of the wire's origin.

Parameters:
name - the name of the property.
value - the string value of the property.
See Also:
getOrigin()

addProperty

public void addProperty(byucc.jhdl.base.Property p)
Deprecated. If you're using this addProperty, you're probably using it incorrectly. Use addProperty(Cell parent, String name, String value) instead to specify the scope of the property on this wire.

Used to add a Property object to a Wire, at the scope of the wire's origin.

Parameters:
p - the property object.
See Also:
getOrigin()

getProperties

public byucc.jhdl.base.PropertyList getProperties(byucc.jhdl.base.Cell parent)
Used to get the property list from the wire from the scope of the given cell.

Parameters:
parent - the cell that defines the scope of the property.
Returns:
the property list for this wire.

getProperty

public byucc.jhdl.base.Property getProperty(byucc.jhdl.base.Cell parent,
                                            String name)

getPropertyValue

public Object getPropertyValue(byucc.jhdl.base.Cell parent,
                               String name)

getProperty

public byucc.jhdl.base.Property getProperty(String name)

getPropertyValue

public Object getPropertyValue(String name)

hasProperties

public boolean hasProperties(byucc.jhdl.base.Cell parent)
Used to determine if this wire has properties, at the scope of the given cell.

Parameters:
parent - the cell that defines the scope of the property.
Returns:
true if properties were added to this particular wire alias.

getProperties

public byucc.jhdl.base.PropertyList getProperties()
Used to get the property list from the wire, at the scope of the wire origin.

Returns:
the property list for this wire.

hasProperties

public boolean hasProperties()
Used to determine if this wire has properties.

Returns:
true if properties were added to this particular wire alias.

replaceProperty

public void replaceProperty(byucc.jhdl.base.Cell parent,
                            String name,
                            String value)
Used to replace a string property of a Wire. If the property already exists, its value is changed; if the property does not exist, it is created.

Parameters:
parent - the cell that defines the scope of the property.
name - the name of the property to add or replace
value - the new value of the property

replaceProperty

public void replaceProperty(byucc.jhdl.base.Cell parent,
                            byucc.jhdl.base.Property p)
Used to replace a property of a Wire. If the property already exists, its value is changed; if the property does not exist, it is created.

Parameters:
parent - the cell that defines the scope of the property.
p - the new version of the property.

replaceProperty

public void replaceProperty(String name,
                            String value)
Used to replace a string property of a Wire, within the scope of the wire origin. If the property already exists, its value is changed; if the property does not exist, it is created.

Parameters:
name - the name of the property to add or replace
value - the new value of the property

replaceProperty

public void replaceProperty(byucc.jhdl.base.Property p)
Used to replace a property of a Wire, within the scope of the wire origin. If the property already exists, its value is changed; if the property does not exist, it is created.

Parameters:
p - the new version of the property.

removeProperty

public boolean removeProperty(byucc.jhdl.base.Cell parent,
                              String name)
Used to remove a named property of a Wire at the scope of the given cell. If the wire does not have a property by that name, nothing is done.

Parameters:
parent - the cell that defines the scope of the property.
name - the name of the property to remove
Returns:
true if a property was removed, false if no change

removeProperty

public boolean removeProperty(String name)
Used to remove a named property of a Wire at the scope of the wire origin. If the wire does not have a property by that name, nothing is done.

Parameters:
name - the name of the property to remove
Returns:
true if a property was removed, false if no change

addProperties

public void addProperties(byucc.jhdl.base.Cell parent,
                          byucc.jhdl.base.PropertyList plist)
Used to add a list of properties to the Wire, within the scope of the given cell.

Parameters:
parent - the cell that defines the scope of the property.
plist - the list of properties to add.
Throws:
BuildException - if a property already exists

addProperties

public void addProperties(byucc.jhdl.base.Cell parent,
                          byucc.jhdl.base.PropertyList plist,
                          boolean warn_duplicates)
Used to add a list of properties to the Wire, withing the scope of the given cell. This version can ignore errors created by clashes, replacing the old property with the new; or throw an exception explaining the properties that clashed. Before an exception is thrown, all properties that do not clash will be added.

Parameters:
parent - the cell that defines the scope of the property.
plist - the list of properties to add.
warn_duplicates - true to have an exception on duplicates, false to force an override of any duplicates
Throws:
BuildException - if a property already exists and warn_duplicates is true

addProperties

public void addProperties(byucc.jhdl.base.PropertyList plist)
Used to add a list of properties to the Wire, within the scope of the wire origin.

Parameters:
plist - the list of properties to add.
Throws:
BuildException - if a property already exists

addProperties

public void addProperties(byucc.jhdl.base.PropertyList plist,
                          boolean warn_duplicates)
Used to add a list of properties to the Wire, within the scope of the wire origin. This version can ignore errors created by clashes, replacing the old property with the new; or throw an exception explaining the properties that clashed. Before an exception is thrown, all properties that do not clash will be added.

Parameters:
plist - the list of properties to add.
warn_duplicates - true to have an exception on duplicates, false to force an override of any duplicates
Throws:
BuildException - if a property already exists and warn_duplicates is true

getOrigin

public Wire getOrigin()
This returns the original wire that created the bits of this wire. If this is a multi-bit wire, it is possible that there are more than one wire origins, but the one that is returned corresponds to the least significant bit.

Returns:
the origin of the least-significant bit of the attached wire, that is, the wire which created the bits used by this wire.

hasBeenPut

public boolean hasBeenPut()