The HDF Group

HDF Reference Manual


[HE Interface][Top]


HEclear

VOID HEclear( )

Purpose
Clears all information on reported errors from the error stack.
Return value
None.
Description
HEpush creates an error stack. HEclear is then used to clear this stack after all errors are processed or when desired.

[HE Interface][Top]


HEpush

VOID HEpush(int16 error_code, char *funct_name, char *file_name, intn line)

error_code
IN:
HDF error code corresponding to the error
func_name
IN:
Name of function in which the error occurred
file_name
IN:
Name of file in which the error occurred
line
IN:
Line number in the file that error occurred

Purpose
Pushes a new error onto the error stack.
Return value
None.
Description
HEpush pushes the file name, function name, line number, and generic description of the error onto the error stack. HEreport can then be used to give a more case-specific description of the error.
 
If the stack is full, the error will be ignored. HEpush assumes that the character strings func_name and file_name are in semi-permanent storage, so only pointers to the strings are saved.

[HE Interface][Top]


HEreport

VOID HEreport(char *format, ... )

format
IN:
Output string specification

Purpose
Adds a text string to the description of the most-recently-reported error (only one text string per error).
Return value
None
Description
HEpush places on the error stack the file name, function name, line number, and a generic description of the error type. HEreport can then be used to give a more case-specific description of the error. Only one additional annotation can be attached to each error report.
 
The format argument must conform to the string specification requirements of printf.

[HE Interface][Top]


HEvalue

int16 HEvalue(int32 level)

level
IN:
Level of the error stack to be returned

Purpose
Returns an error code from the specified level of the error stack.
Return value
The error code if successful or DFE_NONE otherwise.
Description
HEvalue returns the error code at the top of the stack, when level is 1. Refer to Table 1B of Section 1 in this reference manual for a complete list of HDF4 error codes.


HDF4.2r4 - February 2009
Copyright
The HDF Group
www.hdfgroup.org
The HDF Group