NBS_GET_CVALUE
- Get a character string from a slice of a primitive item
associated with the specified identifier
Description:
Extracts the string data pointer and string length from the
FORTRAN argument list, and passes this information to NBS_GET_VALUE.
Thus, the number of bytes read is at most the length the string
supplied.
Identifier of the item from which thew value is to be got.
OFFSET = INTEGER (Given)
Byte offset into item data.
STRING = CHARACTER*(*) (Returned)
Users string buffer into which item bytes will be got.
ACTBYTES = INTEGER (Returned)
Actual number of values associated with the item. This may be
greater than OFFSET + LEN(STRING) but no more than LEN(STRING) bytes
will be copied into the user's buffer.
STATUS = INTEGER (Given and returned)
The global status. Possible return values are,
NBS__NILID NIL ID
NBS__NOTPRIMITIVE Item is not primitive
NBS__BADOFFSET Negative offset specified
NBS__TIMEOUT Timeout awaiting valid data
Notes:
No C version of this routine is supplied because C strings are
by convention null terminated. As NBS_GET_CVALUE writes new
string data, its correct functioning in the C case would rely on
the unwarranted assumption that sufficient space existed in the
destination string for the data to be written. By forcing the use
of NBS_GET_VALUE in this case, the user must at least state the
destination length explicitly.