The commands that perform import and export of extension data are defined in the usual way via environment variables whose names are formed by prefixing `NDF_IMP_' or `NDF_EXP_' to the extension name (in upper case), for example:
setenv NDF_IMP_CCDPACK 'impccd ndf=^ndf' setenv NDF_EXP_CCDPACK 'expccd ndf=^ndf'
Here, the extension name is CCDPACK (and should appear in the NDF_XTN list) and the ``impccd'' and ``expccd'' utilities are assumed to have been written to import and export information for this extension.
The commands are invoked after message token substitution has taken
place, as described in §. In this case,
the set of tokens defined for use is as follows:
As explained earlier, the foreign format file should not normally be accessed by import and export utilities unless that is unavoidable, so one set of import and export commands will normally suffice for accessing a whole range of foreign formats.
In special cases, however, where techniques specific to a particular format are needed, an alternative set of commands may be defined to apply to that format alone. This is done via environment variables whose names are constructed by appending an underscore and the foreign format name to the usual names shown above. For instance, when importing and exporting CCDPACK extension information to FIGARO files, one might want to use:
setenv NDF_IMP_CCDPACK_FIGARO 'impccd ndf=^ndf file=^dir^name^type' setenv NDF_EXP_CCDPACK_FIGARO 'expccd ndf=^ndf file=^dir^name^type'
If these variables were defined, they would over-ride any defined without the `_FIGARO' suffix when accessing that particular format. Any special techniques can therefore be restricted to those formats that require them.