Previous: New Routines Up: RTL Routine Changes Next: Deprecated RTL Functionality
This section lists new features and potential incompatibilities of the new RTL that aren't discussed elsewhere or need to be re-emphasized.
The COUNT parameter on zvp, xvip, and zvip behaves like you would expect. It returns the number of parameters given, and 0 if it is a null parameter. However, in xvp, COUNT behaves differently. If the parameter was defaulted (given a default in the PDF but not by the user), then COUNT is returned as 0, regardless of the actual number of parameters in the defaulted value. This is a design flaw that must be maintained for historical reasons. See the discussion of COUNT under x/ zvip above for more details.
The R8FLAG parameter of xvparm and xviparm has been removed. To return double precision real values, use x/ zvparmd or x/ zviparmd. The R8FLAG parameter does still exist in the VMS version for backward compatibility, however, it is only in the VMS version and may disappear in the future.
Strings in the image label are delimited by single quotes ('). In the past, this meant that single quotes could not be included in a label string. With the new RTL, however, this restriction no longer applies. A single quote in an input string (to x/ zladd) will be repeated before being put in the label. On output (from x/ zlget), the pair will be returned as one single quote. In other words, the repeating of quotes is transparent to the application program. Care should be taken when creating labels with single quotes, as older versions of VICAR will not be able to read the file. This problem should disappear in time as the old versions get replaced.
The maximum string length parameter for xvpout has been removed. It was formerly an optional argument, but was not used anywhere in the system. Since the string length can be obtained from the Fortran string itself, it is not needed for the Fortran xvpout call. The length parameter is, however, required on the C-language zvpout call.
The maximum size of a label key has been increased from 8 to 32 characters. This will allow more descriptive labels and will facilitate data exchange with other image formats, such as PDS and FITS. Note that at the present time the length of a task name is still truncated to 8 (only 8 are significant), but when calling x/ zlhinfo you should now provide a 32-character buffer (33 in C for the null terminator) in order to accomodate future expansion. Property names may be up to 32 characters long as well.
You must be careful when using longer label keys, at least at first. An image with a long label key will not be able to be read properly on an older VICAR system. Before using a long label key in an image, make sure that all potential users of the image are using a version of VICAR that handles long label keys.
The TYPE argument to x/ zladd, x/ zldel, x/ zlget, and x/ zlinfo now allows the type ``PROPERTY'' as well as ``SYSTEM'' and ``HISTORY''. ``PROPERTY'' must be specified for the TYPE argument of these routines to access the property labels. See Section , Property Labels, for more information.
Under Unix, filenames accepted by the RTL (via x/ zvunit, either the U_NAME optional or the INP or OUT parameters) now can contain environment variables and usernames. A reference of the form $ var will be replaced with the value of the environment variable var. The name of the environment variable (but not the dollar sign) may optionally be enclosed in curly braces (${ var}). A tilde ( ) followed by a username will be replaced with the home directory of that user. A tilde without a username will be replaced with the home directory of the current account. Both of these expansions exactly mimic the behavior of the C-shell, so they should be familiar to most Unix users.
In addition, if a filename begins with a plus sign (+), the file is treated as a temporary file. It is created (or accessed) in the directory pointed at by the environment variable $VTMP, which is normally set to /tmp/ username, where username is the username of the current account. The VMS VICAR style of specifying temporary filenames (by leaving off the filename extension, which is replaced with a .Z xx extension), is not supported under Unix. If you do not put an extension on the filename, then the file will be created without one, as you specified. The + form of temporary file will be supported in VMS in the future. It is possible that the translation of the temporary names to physical locations may change in the future, in order to allow different filenames for different processes. However, the + form of specifying the name will not change.