Skip to content
Start free evaluation

pdcomm_gem_result_directory_get

Function

Copies one field of one entry of a validated S1F22 or S1F24 reply.

PdcommStatus pdcomm_gem_result_directory_get(const PdcommGemResult *result, size_t index, uint32_t field, PdcommSecsItem **out_item)

Declared in: #include <pdcomm_gem_directories.h>

Data variable entries accept #PDCOMM_GEM_DIRECTORY_NAME and #PDCOMM_GEM_DIRECTORY_UNITS (ASCII items). Event entries accept #PDCOMM_GEM_DIRECTORY_NAME (ASCII item) and #PDCOMM_GEM_DIRECTORY_VARIABLE_IDS (one U4 array item).

Parameters

NameDescription
resultResult with outcome #PDCOMM_GEM_DATA_DIRECTORY_RECEIVED or #PDCOMM_GEM_EVENT_DIRECTORY_RECEIVED.
indexZero-based entry position.
fieldField selector valid for the entry type.
out_itemReceives the new item; set to NULL first. Must not be NULL.

Returns

#PDCOMM_OK on success; #PDCOMM_INVALID_ARGUMENT when result or out_item is NULL or field is not accepted for the entry type; #PDCOMM_INVALID_STATE when result is an invalid, failed, or unrelated result; #PDCOMM_OUT_OF_RANGE when index is not less than the entry count; #PDCOMM_INVALID_DATA, #PDCOMM_LIMIT_EXCEEDED, #PDCOMM_ALLOCATION_FAILED, or #PDCOMM_INTERNAL_ERROR.

Notes

  • Ownership: release the item with pdcomm_secs_destroy().