[Back to Interface] [Prev] [Next]

ANget_tagref/afgettagref

int32 ANget_tagref(int32 an_id, int32 index, ann_type annot_type, uint16 *ann_tag, uint16 *ann_ref)

an_id IN:

AN interface identifier returned by ANstart

index IN:

Index of the annotation

annot_type IN:

Type of the annotation

ann_tag OUT:

Tag of the annotation

ann_ref OUT:

Reference number of the annotation

Purpose

Retrieves the tag/reference number pair of an annotation given its index and type.

Return value

Returns SUCCEED (or 0) if successful or FAIL (or -1) otherwise.

Description

ANget_tagref retrieves the tag and reference number of the annotation identified by its index, the parameter index, and by its annotation type, the parameter annot_type. The tag is stored in the parameter ann_tag and the reference number is stored in the parameter ann_ref.

The parameter index is a nonnegative integer and is less than the total number of annotations of type annot_type in the file. Use ANfileinfo to obtain the total number of annotations of each type in the file.

The following table lists the valid values of the parameter annot_type in the left column, and the corresponding values of the parameter ann_tag in the right column.

Annotation Type
Annotation Tag
AN_DATA_LABEL (or 0) DFTAG_DIL (or 104)
AN_DATA_DESC (or 1) DFTAG_DIA (or 105)
AN_FILE_LABEL (or 2) DFTAG_FID (or 100)
AN_FILE_DESC (or 3) DFTAG_FD (or 101)

FORTRAN

integer function afgettagref(an_id, index, annot_type, ann_tag, ann_ref)

integer an_id, index, annot_type

integer ann_tag, ann_ref



[Back to Interface] [Prev] [Next]

hdfhelp@ncsa.uiuc.edu
HDF Reference Manual - 07/29/98, NCSA HDF Development Group.