next up previous
Next: File Format Up: Overview of Library Routines Previous: Mid Level Routines


Low Level Routines

There are a number of low-level routines available to advanced programmers. CMSV_OPEN is used to open save files for reading and writing (the normal CLOSE is used to close the file when finished). CMSV_RREC and CMSV_WREC read and write most record types from a save file. CMSV_RVTYPE and CMSV_RDATA read a variables type and data respectively; CMSV_WVTYPE and CMSV_WDATA perform the equivalent writing function.

It is best to examine the upper level routines such as CMSVREAD or CMSAVEDIR to understand how these high level routines are to be used.

Programmers who wish to use the CMSAVE library should first include the following code in their initialization routine. This will guarantee that the CMSAVE library is fully functional.

catch, catcherr
if catcherr EQ 0 then lib = cmsvlib(/query) else lib = 0
catch, /cancel
if lib EQ 0 then $
  message, 'ERROR: The CMSVLIB library must be in your IDL path.'
In place of the MESSAGE call, any graceful failure action can be taken.



Craig Markwardt 2011-12-21