[Back to Interface] [Next]

SDattrinfo/sfgainfo

intn SDattrinfo(int32 obj_id, int32 attr_index, char *attr_name, int32 *data_type, int32 *count)

obj_id IN:

Identifier of the object to which the attribute is attached to

attr_index IN:

Index of the attribute

attr_name OUT:

Name of the attribute

data_type OUT:

Data type of the attribute values

count OUT:

Total number of values in the attribute

Purpose

Retrieves information about an attribute.

Return value

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

Description

SDattrinfo retrieves the name, data type, and number of values of the attribute specified by its index, attr_index, and stores them in the parameters attr_name, data_type, and count, respectively. This routine should be used before reading the values of an attribute with SDreadattr.

The parameter obj_id can be either an SD interface identifier (sd_id), returned by SDstart, a data set identifier (sds_id), returned by SDselect, or a dimension identifier (dim_id), returned by SDgetdimid.

Valid values of the parameter attr_index range from 0 to the number of attributes attached to the object - 1.

Valid values of the parameter data_type can be found in Table 1A of Section I of this manual.

FORTRAN

integer function sfgainfo(obj_id, attr_index, attr_name, data_type, count)

character*(*) attr_name

integer obj_id, attr_index, data_type, count



[Back to Interface] [Next]

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