The H5G_LINK procedure creates a link of the specified type. A link can only point to one of the three classes of named objects: group, dataset, and named datatype.

Example


See the example under H5F_CREATE.

Syntax


H5G_LINK, Loc_id, Current_Name, New_Name [, /SOFTLINK] [, NEW_LOC_ID=value]

Arguments


Loc_id

An integer giving the file or group identifier.

Current_Name

String name of the existing object if link is a hard link. Can be anything for the soft link.

When creating a soft link Current_Name can be absolute or relative and may include path information.

For example, to create a link to an object that exists in the current group use the name of the object:

Object1

To create a link to an object that exists in a sub group of the current group use a relative path name:

Subgroup/Object1 or ./Subgroup/Object1

To create a link to an object that exists outside of the current group use an absolute path (a path beginning with the root group of the file, ‘/’):

/Group1/Object1

New_Name

New string name for the object.

Keywords


SOFTLINK

If set the link will be a soft link. The default is to create a hard link.

NEW_LOC_ID

An integer giving the file or group identifier for the new link. This keyword is only used when linking to an object in a different file or group.

Version History


6.2

Introduced

See Also


H5G_CREATE, H5G_UNLINK