18.2.103. PMIx_Info_list_add
PMIx_Info_list_add — Append a key/value entry to an opaque
pmix_info_t(5) list
18.2.103.1. SYNOPSIS
#include <pmix.h>
pmix_status_t PMIx_Info_list_add(void *ptr,
const char *key,
const void *value,
pmix_data_type_t type);
18.2.103.1.1. Python Syntax
No Python equivalent
18.2.103.2. INPUT PARAMETERS
ptr: Opaque list handle returned by PMIx_Info_list_start(3).key: String key to be loaded. Must be no longer thanPMIX_MAX_KEYLEN.value: Pointer to the data value to be loaded.type: The pmix_data_type_t(5) of the provided value.
18.2.103.3. DESCRIPTION
Create a new pmix_info_t entry from the provided
key, value, and type, and append it to the end of the list
identified by ptr. The key and value are copied into the entry, so the
caller’s source key and any data referenced by value may be modified or
freed once the function returns without affecting the stored copy.
This routine does not check for a duplicate key; if the same key is added more than once, multiple entries with that key will appear on the list. Use PMIx_Info_list_add_unique(3) when duplicate suppression is required.
18.2.103.4. RETURN VALUE
Returns PMIX_SUCCESS on success, or a negative PMIx error constant on
failure — most commonly PMIX_ERR_NOMEM if the entry could not be
allocated.