next up previous
Next: TUNING
Up: HDS Hierarchical Data System
Previous: ENQUIRIES

PACKAGED ROUTINES  

HDS provides families of routines which provide a more convenient method of access to objects than the basic routines. For instance DAT_PUTnx and DAT_GETnx package DAT_PUT and DAT_GET by dimensionality and type. Thus DAT_PUT0I will write a single INTEGER value to a scalar primitive. DAT_GET1R will read the value of a vector primitive and store it in a REAL program array. There are no DAT_GET2x routines; all dimensionalities higher than one are handled by DAT_GETNx and DAT_PUTNx.

Another family of routines are the CMP_ routines. These access components of the "current level". This usually involves:

The CMP_ routines package this sort of operation, replacing three or so subroutine calls with one. The naming scheme is based on the associated DAT_ routines. An example is shown below.

      ...
      CHARACTER * 80 DLAB
      INTEGER DIMS( 2 )
      REAL IMVALS( 512, 1024 )
      DATA DIMS / 512, 1024 /

*  Get REAL values from the DATA_ARRAY component.
      CALL CMP_GETNR( NLOC, 'DATA_ARRAY', 2, DIMS, IMVALS, DIMS, STATUS )

*  Get a character string from the LABEL component and store it in DLAB.
      CALL CMP_GET0C( NLOC, 'LABEL', DLAB, STATUS )
      ...



next up previous
Next: TUNING
Up: HDS Hierarchical Data System
Previous: ENQUIRIES

HDS Hierarchical Data System
Starlink User Note 92
R.F. Warren-Smith & M.D. Lawden
23rd February 1999
E-mail:rfws@star.rl.ac.uk

Copyright (C) 1999 Central Laboratory of the Research Councils