Xilinx 8.2i Life Jacket User Manual


 
90 www.xilinx.com Development System Reference Guide
Chapter 3: Tcl
R
object_name specifies the object to return the name of. The object name will always be a
string. The set command can be used to create a Tcl variable, as shown in the following
example.
properties (list object properties)
The object properties command lists the available properties for the specified object.
% object properties <object_name>
object is the name of the Xilinx Tcl command.
name is the name of the object subcommand.
object_name specifies the object to list the properties of. The object name will always be a Tcl
variable created with the Tcl set command.
Example: % set colVar [search * -type instance]
% object name [collection index $colVar 1]
Description: In this example, the set command is first used to create the colVar
collection variable. The nested search command defines the value of
the collection variable to be all instances in the current ISE project.
In the second line, the object name command is used to get the name
of the second object in the collection. The collection index command
defines which object to get, where:
$colvar specifies the collection to get the object from.
1 specifies the index into the collection. In this case, the second object
in the collection is returned because index values start at 0. See the
collection index command for more information.
Tcl Return: The name of the object as a text string.
Example: % set colVar [search * -type partition]
% collection foreach obj $colVar {set objProps
[object properties $obj] foreach prop $objProps
{puts [object get $obj $prop]}}
Description: This example first runs a search to create a collection of objects. The
second statement iterates through the objects in the collection. For
each object, a list of available properties for the object are obtained
with the object properties command. Then, the value of each
property is returned for each object.
Tcl Return: The available object properties as a text string.