Files
sics/doc/manager/alias.htm
2000-02-07 10:38:55 +00:00

46 lines
1.6 KiB
HTML

<HTML>
<HEAD>
<TITLE>Aliases in SICS</TITLE>
</HEAD>
<BODY>
<H1>Aliases in SICS</H1>
<P>
SICS knows two different kinds of aliases: object aliases and command
aliases. This is confusing but finds its explanation in the structure
of SICS internals.
</P>
<h2>Object Aliases</h2>
<p>
An object alias is another name for a first class object installed
into the SICS interpreter. For instance a second name for a motor. For
instance the motor twotheta is quite often aliased to a4. Such an
alias can be used like a normal SICS objects. Even in commands which
access internal SICS interfaces like the drive command or
others. Object aliases are installed into SICS with the SICSAlias
command:
<DL>
<DT>SicsAlias newname oldname
<DD>This command installs newname as alias for the object oldname.
</dl>
SicsAlias can only be used within initialization scripts.
</p>
<h2>Command Aliases</h2>
<p>
Command aliases are shortcuts for lengthy commands. For instance one
might want to define A4LL as a shortcut for "a4 softlowerlim". This is
just to save typing or adapt SICS to MAD users who appear to have an
unlimited memory for 2-4 letter acronyms. It is possible to redefine a
SICS object with this for instance to define tt as an alias for
temperature. However if one tries to use tt in a drive command it will
fail because it is just a text replacement. A command alias can be
installed into SICS at any time with manager privilege and the
command:
<DL>
<DT>alias shortcut bla bla bla ....
<DD>This define shortcut as an alias for everything behind it.
</DL>
A shortcut may take parameters.
</p>
</BODY>
</HTML>