File 'cmd.tcl' (part of 'ParseTools')


Home | Packages | Files | Procedures | Keywords


Written by
Andreas Kupries ([email protected])
Description
A database allowing the association of arbitrary information with commands (-> command attributes). Future vision is to have that database built into the core interpreter and new commands (from extension and packages) automatically filling it with some standard information, f.e. about arguments, return values, semantic promises (like: 'does not affect/fire traces'), etc.

::parsetools::cmd::__Load__ ()

Internal command. Used by other parts of the system to enforce the loading of this module.

::parsetools::cmd::append (name attr value)

Manipulates an existing attribute of the named command. The specified value is appended to the current value of the attribute, while treating that one as a string.
Argument: name The name of the command whose attribute is manipulated.
Argument: attr The name of the attribute.
Argument: value The data to add to the attribute.
Returns: the new value of the attribute.

::parsetools::cmd::del (name attr)

Deletes the specified attribute for the named command.
Argument: name The name of the command whose attribute is manipulated.
Argument: attr The name of the attribute to delete.

::parsetools::cmd::get (name attr)

Retrieves the current value of the specified attribute for the named command.
Argument: name The name of the command whose attribute is queried
Argument: attr The name of the queried attribute.

::parsetools::cmd::getattrs (name)

Argument: name The name of the queried command.
Returns: a list containing the names of the attributes associated to the specified command and their values, in a form accepted by array set.

::parsetools::cmd::lappend (name attr value)

Manipulates an existing attribute of the named command. The specified value is appended to the current value of the attribute, while treating that one as a list.
Argument: name The name of the command whose attribute is manipulated.
Argument: attr The name of the attribute.
Argument: value The data to add to the attribute.
Returns: the new value of the attribute.

::parsetools::cmd::remove (name)

Removes all information about the named command from the database.
Argument: name The name of the command whose information shall be removed.

::parsetools::cmd::set (name attr value)

Assign a value to an attribute of the named command. Defines a new attribute if it does not exist already.
Argument: name The name of the command whose attribute is manipulated.
Argument: attr The name of the attribute.
Argument: value The new value of the attribute.
Returns: the value.


Home | Packages | Files | Procedures | Keywords



Generated by AutoDoc 2.3 at 04/27/2001, invoked by Andreas Kupries,,,