Convert a single value¶
_saf_convert
is a function defined in utils.c.
Synopsis:
-
void *
_saf_convert
(hid_t srctype, const void *srcbuf, hid_t dsttype, void *dstbuf)¶
Formal Arguments:
srctype
: Source datatype; type ofsrcbuf
value.srcbuf
: Source datum to be converted to a new type.dsttype
: Destination datatype; type ofdstbuf
value.dstbuf
: Optional destination buffer. If not supplied then a buffer is allocated.
Description: Converts a single value from one datatype to another. This is most often used to convert a runtime typed value into an integer to be used by the library.
Return Value: Returns dstbuf
(or an allocated buffer if dstbuf
is null) on success; returns null on failure.
Parallel Notes: Independent
See Also:
- Data Types: Introduction for current chapter