PRINTLOG - Captures a transcript of console output
PRINTLOG captures and archives a copy of any output sent to the
console. PRINTLOG is used exactly like PRINT and sends its output to
the screen as expected. However, it additionally saves a verbatim
copy of the output. This can be especially useful if an independent
session log is needed (like JOURNAL), or if a strict transaction
history is required. In order to use this procedure, you must change
your code to use PRINTLOG instead of PRINT, and maintain a string
variable which holds the log.
TRANSREAD - Read ASCII tables quickly and with ease
TRANSREAD parses an ASCII table into IDL variables, one variable
for each column in the table. The tabular data is not limited to
numerical values, and can be processed with an IDL FORMAT
expression.
TRANSREAD behaves similarly to READF/READS in that it transfers
ASCII input data into IDL variables. The difference is that
TRANSREAD reads more than one row in one pass, and returns data by
column. In a sense, it forms the transpose of the typical
output from READF or READS (which returns data by row), hence the
name TRANSREAD.
Feature highlights include:
- FORMAT expression is optionally accepted.
- Comment lines can optionally be recognized and ignored.
- Standalone operation. No other IDL procedures are needed.
- Input is either a file unit or a string array.
- Start and Stop "Cue" Phrases can be used to begin and end
the parsing operation.
- Extensive documentation is included in the header of
TRANSREAD.PRO itself.
PATHUTILS - Form relative and normalized file path names
The routines RELPATH and NORMPATH are used to construct relative
and normalized file system path names. RELPATH constructs a relative
path between two files or directories. For example, the relative path
from /path/to/directory/one to /path/to/file/two is ../../file/two.
NORMPATH normalizes a path so that the shortest possible path is
returned, and relative path components are removed if possible. For
example, the path /path/to/directory/one/../file/two can be normalized
to /path/to/file/two. If an absolute path is not possible, then the
shortest relative path is returned.
Both routines should be system independent, but have been tested on
Unix.
FXGPKG - Read and seek on pipes like normal files (Unix)
This is an embryonic library of routines which will read, write,
and seek on arbitrary Unix streams such as pipes and URLs. The most
important thing is the seek capability, which allows you to
address any point in the stream with random access rather than
sequential access.
At present, only Unix pipes are accessible. Eventually it is
desired to be able to read from generic URLs and shared memory using
third party such as CURL. The current implementation is to store the
contents of the Unix pipe in a temporary cache file. Unfortunately,
the input/output is limited to unformatted binary content.
All of the routines are required, and you may wish to download the
entire archive in one file as either a gzip'ed tar file or zip file.
The routines are internally documented, but you should probably
start with FXGOPEN.PRO.
|