### HDS_COPY

Copy an object to a new container file

#### Description:

The routine makes a copy of an HDS object, placing the copy in a new container file (which is created), as the top-level object. The copying operation is recursive; i.e. all sub-components of a structure will also be copied.

#### Invocation

CALL HDS_COPY( LOC, FILE, NAME, STATUS )

#### Arguments

##### LOC = CHARACTER $\ast$ ( DAT__SZLOC ) (Given)
Locator for the object to be copied.
##### FILE = CHARACTER $\ast$ ( $\ast$ ) (Given)
Name of the new container file to be created.
##### NAME = CHARACTER $\ast$ ( $\ast$ ) (Given)
Name which the new top-level object is to have.
##### STATUS = INTEGER (Given and Returned)
The global status.

#### Notes:

• This routine attempts to eliminate unused space during the copying operation and is therefore a useful method of compressing a container file from which components have been deleted.

• The routine may be used to copy both primitive and structured objects, but cannot be used to make a copy of a cell or a slice.