Typedef anjay_nidd_driver_recv_t
Defined in File nidd.h
Typedef Documentation
-
typedef int anjay_nidd_driver_recv_t(anjay_nidd_driver_t *driver, size_t *out_bytes_received, void *out_message, size_t size, avs_time_monotonic_t deadline)
Attempts to receive entire message over NIDD to
out_message.NOTE: If the device has no message to return within the
timeout, it MUST not block, return negative value and set driver errno to AVS_ETIMEDOUT.NOTE: If the
out_messageis too small to hold an entire message, the function MUST fail with driver errno set to AVS_EMSGSIZE.- Param driver:
Device driver context to operate on.
- Param out_bytes_received:
Pointer to a variable that, on successful exit, MUST be set to the number of bytes successfully read into
out_message.- Param out_message:
Message buffer to write to.
- Param size:
Maximum message size in bytes.
- Param deadline:
Deadline of the operation.
- Return:
0 on success, negative value in case of error. Driver errno MUST be set to a non-zero value if the function fails.