DTNMA Reference Tools v2.1.0 - 13.gc5c0bac
Delay-Tolerant Networking Management Architecture (DTNMA) Tool Suite
Loading...
Searching...
No Matches
access.c File Reference
#include "access.h"
#include "cace/util/defs.h"
#include <timespec.h>
+ Include dependency graph for access.c:

Functions

bool cace_ari_is_undefined (const cace_ari_t *ari)
 Determine if a value is the undefined value.
 
bool cace_ari_not_undefined (const cace_ari_t *ari)
 Determine if a value is not the undefined value.
 
void cace_ari_set_undefined (cace_ari_t *ari)
 Set the ARI value to be undefined.
 
bool cace_ari_is_null (const cace_ari_t *ari)
 Determine if this is a typed or untyped null value.
 
void cace_ari_set_null (cace_ari_t *ari)
 Set the ARI value to be untyped null.
 
bool cace_ari_is_bool (const cace_ari_t *ari)
 Determine if this ARI contains a primitive boolean type.
 
int cace_ari_get_bool (const cace_ari_t *ari, bool *out)
 Extract a boolean value, if present, from an ARI.
 
void cace_ari_set_prim_bool (cace_ari_t *ari, cace_ari_bool src)
 Set an ARI as an untyped literal value.
 
void cace_ari_set_prim_uint64 (cace_ari_t *ari, uint64_t src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_prim_int64 (cace_ari_t *ari, int64_t src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_prim_float64 (cace_ari_t *ari, cace_ari_real64 src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
int cace_ari_get_int (const cace_ari_t *ari, cace_ari_int *out)
 Extract an integer value, if present, from an ARI.
 
int cace_ari_get_uint (const cace_ari_t *ari, cace_ari_uint *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
int cace_ari_get_byte (const cace_ari_t *ari, cace_ari_byte *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
int cace_ari_get_vast (const cace_ari_t *ari, cace_ari_vast *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
int cace_ari_get_uvast (const cace_ari_t *ari, cace_ari_uvast *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_bool (cace_ari_t *ari, cace_ari_bool src)
 Set an ARI as a typed literal value.
 
void cace_ari_set_byte (cace_ari_t *ari, cace_ari_byte src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_int (cace_ari_t *ari, cace_ari_int src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_uint (cace_ari_t *ari, cace_ari_uint src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_vast (cace_ari_t *ari, cace_ari_vast src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_uvast (cace_ari_t *ari, cace_ari_uvast src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_real32 (cace_ari_t *ari, cace_ari_real32 src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_real64 (cace_ari_t *ari, cace_ari_real64 src)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
const cace_data_tcace_ari_cget_tstr (const cace_ari_t *ari)
 Require a TEXTSTR value and get the pointer to its storage.
 
const char * cace_ari_cget_tstr_cstr (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This form casts to const C-string pointer.
 
const char * cace_ari_get_tstr_cstr (cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This form casts to mutable C-string pointer.
 
void cace_ari_set_tstr (cace_ari_t *ari, const char *buf, bool copy)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
const cace_data_tcace_ari_cget_bstr (const cace_ari_t *ari)
 Require a BYTESTR value and get the pointer to its storage.
 
void cace_ari_set_bstr (cace_ari_t *ari, cace_data_t *src, bool copy)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
int cace_ari_get_tp (const cace_ari_t *ari, struct timespec *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The output in this case is in the DTN time epoch.
 
int cace_ari_get_tp_posix (const cace_ari_t *ari, struct timespec *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The output in this case is in the POSIX time epoch.
 
void cace_ari_set_tp (cace_ari_t *ari, struct timespec dtntime)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The input in this case is in the DTN time epoch.
 
void cace_ari_set_tp_posix (cace_ari_t *ari, struct timespec ptime)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The input in this case is in the POSIX time epoch.
 
int cace_ari_get_td (const cace_ari_t *ari, struct timespec *out)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_td (cace_ari_t *ari, struct timespec delta)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_label_int (cace_ari_t *ari, cace_ari_int value)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_label_tstr (cace_ari_t *ari, const char *buf, bool copy)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_aritype (cace_ari_t *ari, cace_ari_type_t type)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void cace_ari_set_aritype_text (cace_ari_t *ari, cace_ari_type_t type)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
bool cace_ari_is_lit_typed (const cace_ari_t *ari, cace_ari_type_t typ)
 Determine if this is a typed literal of a specific type.
 
const int64_t * cace_ari_get_aritype_int (const cace_ari_t *ari)
 Require an ARITYPE literal value.
 
struct cace_ari_ac_s * cace_ari_get_ac (cace_ari_t *ari)
 Require an AC value and extract a pointer to its item list.
 
const struct cace_ari_ac_s * cace_ari_cget_ac (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
struct cace_ari_ac_s * cace_ari_set_ac (cace_ari_t *ari, struct cace_ari_ac_s *src)
 Set the ARI as an AC, optionally moving values from an external source.
 
struct cace_ari_am_s * cace_ari_get_am (cace_ari_t *ari)
 Require an AM value and extract a pointer to its item list.
 
const struct cace_ari_am_s * cace_ari_cget_am (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
struct cace_ari_am_s * cace_ari_set_am (cace_ari_t *ari, struct cace_ari_am_s *src)
 Set the ARI as an AM, optionally moving values from an external source.
 
struct cace_ari_tbl_s * cace_ari_get_tbl (cace_ari_t *ari)
 
const struct cace_ari_tbl_s * cace_ari_cget_tbl (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
struct cace_ari_tbl_s * cace_ari_set_tbl (cace_ari_t *ari, struct cace_ari_tbl_s *src)
 Set the ARI as a TBL, optionally moving values from an external source.
 
struct cace_ari_execset_s * cace_ari_get_execset (cace_ari_t *ari)
 Require an EXECSET value and extract a pointer to its struct.
 
const struct cace_ari_execset_s * cace_ari_cget_execset (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
struct cace_ari_execset_s * cace_ari_set_execset (cace_ari_t *ari)
 Set an ARI as an EXECSET literal value.
 
struct cace_ari_rptset_s * cace_ari_get_rptset (cace_ari_t *ari)
 Require an RPTSET value and extract a pointer to its struct.
 
const struct cace_ari_rptset_s * cace_ari_cget_rptset (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
struct cace_ari_rptset_s * cace_ari_set_rptset (cace_ari_t *ari)
 Set an ARI as an RPTSET literal value.
 
const cace_ari_ref_tcace_ari_cget_ref (const cace_ari_t *ari)
 Require a reference value and extract a pointer to its struct.
 
const cace_ari_objpath_tcace_ari_cget_ref_objpath (const cace_ari_t *ari)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 

Function Documentation

◆ cace_ari_cget_ac()

◆ cace_ari_cget_am()

const struct cace_ari_am_s * cace_ari_cget_am ( const cace_ari_t ari)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_prim_val_u::as_am, cace_ari_t::as_lit, cace_ari_is_lit_typed(), CACE_ARI_TYPE_AM, and cace_ari_lit_t::value.

Referenced by cace_amm_semtype_umap_convert(), and cace_amm_semtype_umap_match().

◆ cace_ari_cget_bstr()

const cace_data_t * cace_ari_cget_bstr ( const cace_ari_t ari)

Require a BYTESTR value and get the pointer to its storage.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained data, if present, otherwise NULL.

References cace_ari_prim_val_u::as_data, cace_ari_t::as_lit, CACE_ARI_PRIM_BSTR, cace_ari_t::is_ref, cace_ari_lit_t::prim_type, and cace_ari_lit_t::value.

Referenced by cace_amm_semtype_cnst_is_valid(), and refda_endpoint_pat_match().

◆ cace_ari_cget_execset()

const struct cace_ari_execset_s * cace_ari_cget_execset ( const cace_ari_t ari)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_prim_val_u::as_execset, cace_ari_t::as_lit, cace_ari_is_lit_typed(), CACE_ARI_TYPE_EXECSET, and cace_ari_lit_t::value.

Referenced by refda_runctx_from(), and refdm_db_insert_execset().

◆ cace_ari_cget_ref()

const cace_ari_ref_t * cace_ari_cget_ref ( const cace_ari_t ari)

Require a reference value and extract a pointer to its struct.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained struct, if present, otherwise NULL.

References cace_ari_t::as_ref, and cace_ari_t::is_ref.

Referenced by cace_amm_type_set_name(), and cace_ari_cget_ref_objpath().

◆ cace_ari_cget_ref_objpath()

const cace_ari_objpath_t * cace_ari_cget_ref_objpath ( const cace_ari_t ari)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_cget_ref(), and cace_ari_ref_t::objpath.

Referenced by builtin_namespace_match(), builtin_object_match(), refda_adm_ietf_dtnma_agent_ctrl_var_reset(), refda_adm_ietf_dtnma_agent_ctrl_var_store(), and refda_exec_proc_ctrl_finish().

◆ cace_ari_cget_rptset()

const struct cace_ari_rptset_s * cace_ari_cget_rptset ( const cace_ari_t ari)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_t::as_lit, cace_ari_prim_val_u::as_rptset, cace_ari_is_lit_typed(), CACE_ARI_TYPE_RPTSET, and cace_ari_lit_t::value.

Referenced by refdm_db_insert_rptset().

◆ cace_ari_cget_tbl()

const struct cace_ari_tbl_s * cace_ari_cget_tbl ( const cace_ari_t ari)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_t::as_lit, cace_ari_prim_val_u::as_tbl, cace_ari_is_lit_typed(), CACE_ARI_TYPE_TBL, and cace_ari_lit_t::value.

Referenced by cace_amm_semtype_tblt_convert(), and cace_amm_semtype_tblt_match().

◆ cace_ari_cget_tstr()

const cace_data_t * cace_ari_cget_tstr ( const cace_ari_t ari)

Require a TEXTSTR value and get the pointer to its storage.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained data, if present, otherwise NULL. @notice This data will always have a terminating null byte.

References cace_ari_prim_val_u::as_data, cace_ari_t::as_lit, CACE_ARI_PRIM_TSTR, cace_ari_t::is_ref, cace_ari_lit_t::prim_type, and cace_ari_lit_t::value.

Referenced by cace_amm_semtype_cnst_is_valid().

◆ cace_ari_cget_tstr_cstr()

◆ cace_ari_get_ac()

struct cace_ari_ac_s * cace_ari_get_ac ( cace_ari_t ari)

Require an AC value and extract a pointer to its item list.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained AC struct, if present, otherwise NULL.

References cace_ari_prim_val_u::as_ac, cace_ari_t::as_lit, cace_ari_is_lit_typed(), CACE_ARI_TYPE_AC, and cace_ari_lit_t::value.

Referenced by refda_adm_ietf_dtnma_agent_ctrl_ensure_sbr(), refda_adm_ietf_dtnma_agent_ctrl_ensure_tbr(), refda_adm_ietf_dtnma_agent_oper_tbl_filter(), and test_refda_reporting_target().

◆ cace_ari_get_am()

struct cace_ari_am_s * cace_ari_get_am ( cace_ari_t ari)

Require an AM value and extract a pointer to its item list.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained AM struct, if present, otherwise NULL.

References cace_ari_prim_val_u::as_am, cace_ari_t::as_lit, cace_ari_is_lit_typed(), CACE_ARI_TYPE_AM, and cace_ari_lit_t::value.

◆ cace_ari_get_aritype_int()

const int64_t * cace_ari_get_aritype_int ( const cace_ari_t ari)

Require an ARITYPE literal value.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained type value, if present, otherwise NULL.

References cace_ari_prim_val_u::as_int64, cace_ari_t::as_lit, cace_ari_is_lit_typed(), CACE_ARI_PRIM_INT64, CACE_ARI_TYPE_ARITYPE, cace_ari_lit_t::prim_type, and cace_ari_lit_t::value.

Referenced by refda_binding_semtype_use().

◆ cace_ari_get_bool()

◆ cace_ari_get_byte()

int cace_ari_get_byte ( const cace_ari_t ari,
cace_ari_byte out 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_prim_val_u::as_int64, cace_ari_t::as_lit, cace_ari_prim_val_u::as_uint64, CACE_ARI_PRIM_INT64, CACE_ARI_PRIM_UINT64, CHKERR1, cace_ari_t::is_ref, cace_ari_lit_t::prim_type, and cace_ari_lit_t::value.

◆ cace_ari_get_execset()

struct cace_ari_execset_s * cace_ari_get_execset ( cace_ari_t ari)

Require an EXECSET value and extract a pointer to its struct.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained struct, if present, otherwise NULL.

References cace_ari_prim_val_u::as_execset, cace_ari_t::as_lit, cace_ari_is_lit_typed(), CACE_ARI_TYPE_EXECSET, and cace_ari_lit_t::value.

Referenced by refda_ingress_push_move(), and refda_ingress_worker().

◆ cace_ari_get_int()

int cace_ari_get_int ( const cace_ari_t ari,
cace_ari_int out 
)

Extract an integer value, if present, from an ARI.

This works for both typed and untyped literal values and will coerce signed and unsigned values to the desired type where possible.

Parameters
[in]ariNon-null pointer to the ARI to read.
[out]outThe value to output, or NULL to not actually get the value just check that it could be.
Returns
Zero upon success.

References cace_ari_prim_val_u::as_int64, cace_ari_t::as_lit, cace_ari_prim_val_u::as_uint64, CACE_ARI_PRIM_INT64, CACE_ARI_PRIM_UINT64, CHKERR1, cace_ari_t::is_ref, cace_ari_lit_t::prim_type, and cace_ari_lit_t::value.

Referenced by alarm_list_filter_sub_label(), cace_amm_type_set_name_aritype(), refda_adm_ietf_alarms_ctrl_set_alarms_manager_state(), refda_adm_ietf_dtnma_agent_ctrl_ensure_const(), refda_adm_ietf_dtnma_agent_ctrl_ensure_odm(), refda_adm_ietf_dtnma_agent_ctrl_ensure_sbr(), refda_adm_ietf_dtnma_agent_ctrl_ensure_tbr(), refda_adm_ietf_dtnma_agent_ctrl_ensure_var(), test_refda_adm_ietf_dtnma_agent_ctrl_ensure_var(), and test_refda_adm_ietf_dtnma_agent_ctrl_var_store_reset().

◆ cace_ari_get_rptset()

struct cace_ari_rptset_s * cace_ari_get_rptset ( cace_ari_t ari)

Require an RPTSET value and extract a pointer to its struct.

Parameters
[in]ariThe ARI to read.
Returns
Pointer to the contained struct, if present, otherwise NULL.

References cace_ari_t::as_lit, cace_ari_prim_val_u::as_rptset, cace_ari_is_lit_typed(), CACE_ARI_TYPE_RPTSET, and cace_ari_lit_t::value.

Referenced by refdm_ingress_worker(), and test_cace_ari_cbor_decode_rptset().

◆ cace_ari_get_tbl()

◆ cace_ari_get_td()

◆ cace_ari_get_tp()

int cace_ari_get_tp ( const cace_ari_t ari,
struct timespec *  out 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The output in this case is in the DTN time epoch.

References cace_ari_t::as_lit, cace_ari_prim_val_u::as_timespec, cace_ari_is_lit_typed(), CACE_ARI_TYPE_TP, CHKERR1, and cace_ari_lit_t::value.

Referenced by cace_ari_cbor_encode_rptset(), refda_adm_ietf_dtnma_agent_ctrl_ensure_tbr(), refda_exec_tbr_next_scheduled_time(), and refdm_db_insert_rptset().

◆ cace_ari_get_tp_posix()

int cace_ari_get_tp_posix ( const cace_ari_t ari,
struct timespec *  out 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The output in this case is in the POSIX time epoch.

References cace_ari_t::as_lit, cace_ari_prim_val_u::as_timespec, cace_ari_dtn_epoch_timespec, cace_ari_is_lit_typed(), CACE_ARI_TYPE_TP, CHKERR1, and cace_ari_lit_t::value.

Referenced by refda_adm_ietf_dtnma_agent_ctrl_wait_until().

◆ cace_ari_get_tstr_cstr()

const char * cace_ari_get_tstr_cstr ( cace_ari_t ari)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This form casts to mutable C-string pointer.

References cace_ari_cget_tstr_cstr().

◆ cace_ari_get_uint()

◆ cace_ari_get_uvast()

int cace_ari_get_uvast ( const cace_ari_t ari,
cace_ari_uvast out 
)

◆ cace_ari_get_vast()

int cace_ari_get_vast ( const cace_ari_t ari,
cace_ari_vast out 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_prim_val_u::as_int64, cace_ari_t::as_lit, cace_ari_prim_val_u::as_uint64, CACE_ARI_PRIM_INT64, CACE_ARI_PRIM_UINT64, CHKERR1, cace_ari_t::is_ref, cace_ari_lit_t::prim_type, and cace_ari_lit_t::value.

Referenced by cace_amm_semtype_cnst_is_valid().

◆ cace_ari_is_bool()

bool cace_ari_is_bool ( const cace_ari_t ari)

Determine if this ARI contains a primitive boolean type.

Parameters
[in]ariNon-null pointer to the ARI to read.
Returns
True if the primitive is boolean.

References cace_ari_t::as_lit, CACE_ARI_PRIM_BOOL, CHKFALSE, cace_ari_t::is_ref, and cace_ari_lit_t::prim_type.

◆ cace_ari_is_lit_typed()

◆ cace_ari_is_null()

◆ cace_ari_is_undefined()

◆ cace_ari_not_undefined()

bool cace_ari_not_undefined ( const cace_ari_t ari)

Determine if a value is not the undefined value.

This can be useful as a CTRL or OPER precondition.

Parameters
[in]ariThe value to check, or a NULL pointer.
Returns
True if the ARI is valid and is not the undefined value.
See also
ARI_UNDEFINED cace_ari_init()

References cace_ari_t::as_lit, CACE_ARI_PRIM_UNDEFINED, CHKFALSE, cace_ari_t::is_ref, and cace_ari_lit_t::prim_type.

Referenced by refda_adm_ietf_dtnma_agent_ctrl_ensure_const(), refda_adm_ietf_dtnma_agent_ctrl_ensure_var(), refda_adm_ietf_dtnma_agent_ctrl_report_on(), refda_reporting_gen(), refda_reporting_target(), and test_refda_alarms_set_state_no_category().

◆ cace_ari_set_ac()

◆ cace_ari_set_am()

struct cace_ari_am_s * cace_ari_set_am ( cace_ari_t ari,
struct cace_ari_am_s *  src 
)

Set the ARI as an AM, optionally moving values from an external source.

Parameters
[in,out]ariThe ARI value to modify.
[in,out]srcAn optional existing value struct to move from.
Returns
The new AC value struct.

References cace_ari_am_init(), cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_OTHER, CACE_ARI_TYPE_AM, CACE_MALLOC, CHKNULL, cace_ari_lit_t::has_ari_type, and cace_ari_am_t::items.

Referenced by cace_amm_semtype_umap_convert().

◆ cace_ari_set_aritype()

◆ cace_ari_set_aritype_text()

void cace_ari_set_aritype_text ( cace_ari_t ari,
cace_ari_type_t  type 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_TSTR, CACE_ARI_TYPE_ARITYPE, cace_ari_type_to_name(), cace_data_init_view(), CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_ari_name(), cace_amm_type_set_use_builtin(), and test_amm_type_set_name_builtin().

◆ cace_ari_set_bool()

◆ cace_ari_set_bstr()

void cace_ari_set_bstr ( cace_ari_t ari,
cace_data_t src,
bool  copy 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_BSTR, cace_data_copy(), cace_data_init(), cace_data_swap(), CHKVOID, and cace_ari_lit_t::has_ari_type.

◆ cace_ari_set_byte()

void cace_ari_set_byte ( cace_ari_t ari,
cace_ari_byte  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_INT64, CACE_ARI_TYPE_BYTE, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_byte_convert(), and refda_adm_ietf_dtnma_agent_edd_exec_running().

◆ cace_ari_set_execset()

struct cace_ari_execset_s * cace_ari_set_execset ( cace_ari_t ari)

Set an ARI as an EXECSET literal value.

Any previous value is de-initialized.

Parameters
[out]ariThe value to set.
Returns
The new execset struct.

References cace_ari_deinit(), cace_ari_execset_init(), cace_ari_init_lit(), CACE_ARI_PRIM_OTHER, CACE_ARI_TYPE_EXECSET, CACE_MALLOC, CHKNULL, and cace_ari_lit_t::has_ari_type.

◆ cace_ari_set_int()

◆ cace_ari_set_label_int()

void cace_ari_set_label_int ( cace_ari_t ari,
cace_ari_int  value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_INT64, CACE_ARI_TYPE_LABEL, CHKVOID, and cace_ari_lit_t::has_ari_type.

◆ cace_ari_set_label_tstr()

void cace_ari_set_label_tstr ( cace_ari_t ari,
const char *  buf,
bool  copy 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_TSTR, CACE_ARI_TYPE_LABEL, cace_data_copy_from(), cace_data_init(), cace_data_init_view(), CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by test_refda_alarms_mgr_state_warning(), and test_refda_alarms_purge_warning().

◆ cace_ari_set_null()

◆ cace_ari_set_prim_bool()

void cace_ari_set_prim_bool ( cace_ari_t ari,
cace_ari_bool  src 
)

Set an ARI as an untyped literal value.

Parameters
[in,out]ariThe ARI to set the value on. This must have been initialized.
srcThe primitive value to set to.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_BOOL, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_bool_convert().

◆ cace_ari_set_prim_float64()

void cace_ari_set_prim_float64 ( cace_ari_t ari,
cace_ari_real64  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_FLOAT64, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by test_ari_text_encode_lit_prim_float64().

◆ cace_ari_set_prim_int64()

void cace_ari_set_prim_int64 ( cace_ari_t ari,
int64_t  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_INT64, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by test_ari_text_encode_lit_prim_int().

◆ cace_ari_set_prim_uint64()

void cace_ari_set_prim_uint64 ( cace_ari_t ari,
uint64_t  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_UINT64, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by test_ari_text_encode_lit_prim_uint(), and test_cace_ari_cbor_encode_lit_prim_uint().

◆ cace_ari_set_real32()

void cace_ari_set_real32 ( cace_ari_t ari,
cace_ari_real32  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_FLOAT64, CACE_ARI_TYPE_REAL32, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_real32_convert().

◆ cace_ari_set_real64()

void cace_ari_set_real64 ( cace_ari_t ari,
cace_ari_real64  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_FLOAT64, CACE_ARI_TYPE_REAL64, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_real64_convert().

◆ cace_ari_set_rptset()

struct cace_ari_rptset_s * cace_ari_set_rptset ( cace_ari_t ari)

Set an ARI as an RPTSET literal value.

Any previous value is de-initialized.

Parameters
[out]ariThe value to set.
Returns
The new rptset struct.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_OTHER, cace_ari_rptset_init(), CACE_ARI_TYPE_RPTSET, CACE_MALLOC, CHKNULL, and cace_ari_lit_t::has_ari_type.

Referenced by refda_reporting_ctrl(), refda_reporting_gen(), and test_cace_ari_cbor_encode_rptset().

◆ cace_ari_set_tbl()

◆ cace_ari_set_td()

void cace_ari_set_td ( cace_ari_t ari,
struct timespec  delta 
)

◆ cace_ari_set_tp()

void cace_ari_set_tp ( cace_ari_t ari,
struct timespec  dtntime 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The input in this case is in the DTN time epoch.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_TIMESPEC, CACE_ARI_TYPE_TP, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_time_convert(), cace_ari_cbor_decode_rptset(), cace_ari_set_tp_posix(), refda_adm_ietf_dtnma_agent_ctrl_ensure_tbr(), refda_agent_nowtime(), test_cace_ari_cbor_encode_lit_typed_tp(), and test_cace_ari_cbor_encode_rptset().

◆ cace_ari_set_tp_posix()

void cace_ari_set_tp_posix ( cace_ari_t ari,
struct timespec  ptime 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The input in this case is in the POSIX time epoch.

References cace_ari_dtn_epoch_timespec, and cace_ari_set_tp().

Referenced by cace_get_system_time(), test_refda_exec_time_based_rule(), and test_refda_exec_wait_until().

◆ cace_ari_set_tstr()

◆ cace_ari_set_uint()

void cace_ari_set_uint ( cace_ari_t ari,
cace_ari_uint  src 
)

◆ cace_ari_set_undefined()

void cace_ari_set_undefined ( cace_ari_t ari)

Set the ARI value to be undefined.

Parameters
[in,out]ariThe value to set, which should not be NULL pointer.

References cace_ari_deinit().

Referenced by builtin_common_convert(), cace_amm_type_get_name(), refda_ctrl_exec_ctx_check_result(), and refda_edd_prod_check_result().

◆ cace_ari_set_uvast()

◆ cace_ari_set_vast()

void cace_ari_set_vast ( cace_ari_t ari,
cace_ari_vast  src 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

References cace_ari_deinit(), cace_ari_init_lit(), CACE_ARI_PRIM_INT64, CACE_ARI_TYPE_VAST, CHKVOID, and cace_ari_lit_t::has_ari_type.

Referenced by builtin_vast_convert(), refda_adm_ietf_dtnma_agent_edd_capability(), suite_adms_init(), suite_adms_init(), and test_refda_adm_ietf_dtnma_agent_ctrl_ensure_var().