DAT_PAREN

Locate parent structure

Description:

The routine returns a locator for the parent structure of an HDS object; i.e. the structure which contains the object.

Invocation

CALL DAT_PAREN( LOC1, LOC2, STATUS )

Arguments

Object locator.
LOC2 = CHARACTER $\ast$ ( DAT__SZLOC ) (Returned)
Parent structure locator.
STATUS = INTEGER (Given and Returned)
The global status.

Notes:

• On successful exit, the parent structure locator will identify a scalar structure (number of dimensions zero). If appropriate, this may be a cell of a structure array.

• An error will result, and the STATUS value DAT__OBJIN will be returned if the object supplied does not have a parent; i.e. if it is the top-level object in a container file. The DAT__OBJIN error code is defined in the include file DAT_ERR.

• If this routine is called with STATUS set, then a value of DAT__NOLOC will be returned for the LOC2 argument, although no further processing will occur. The same value will also be returned if the routine should fail for any reason. The DAT__NOLOC constant is defined in the include file DAT_PAR.

Example

The parent of the object A.B.C.D is A.B.C, the parent of X.DATA.ARRAY(1:256) is X.DATA, and the parent of Z.STRUC(17).FLAG is Z.STRUC(17).