ec_message_context_exists

March 26, 2020 Contributors

Name

ec_message_context_exists — Determines whether a provided key exists in the connection context or message context dictionary

Synopsis

#include "ec_message.h"

| int **ec_message_context_exists** ( | m, |   |
|   | w, |   |
|   | k); |   |

ec_message * <var class="pdparam">m</var>;
int <var class="pdparam">w</var>;
const char * <var class="pdparam">k</var>;

Description

Determine whether a key/value pair exists in either the message context or connection context dictionary.

Parameters

m

A pointer to an ec_message struct. For documentation of this data structure see “ec_message”

w

An int. Valid values are either ECMESS_CTX_CONN or ECMESS_CTX_MESS.

k

A constant string (char *) which is the dictionary key.

Return Values

Returns 1 if the provided key exists in the appropriate dictionary and 0 otherwise.

Threading

It is legal to call this function in any thread.

See Also

ec_message_context_set,ec_message_context_exists_and_get, and ec_message_context_delete