libcoap  4.3.0
coap_cache.c File Reference
+ Include dependency graph for coap_cache.c:

Go to the source code of this file.

Functions

static int is_cache_key (uint16_t option_type, size_t cache_ignore_count, const uint16_t *cache_ignore_options)
 
int coap_cache_ignore_options (coap_context_t *ctx, const uint16_t *options, size_t count)
 Define the CoAP options that are not to be included when calculating the cache-key. More...
 
coap_cache_key_tcoap_cache_derive_key_w_ignore (const coap_session_t *session, const coap_pdu_t *pdu, coap_cache_session_based_t session_based, const uint16_t *cache_ignore_options, size_t cache_ignore_count)
 Calculates a cache-key for the given CoAP PDU. More...
 
coap_cache_key_tcoap_cache_derive_key (const coap_session_t *session, const coap_pdu_t *pdu, coap_cache_session_based_t session_based)
 Calculates a cache-key for the given CoAP PDU. More...
 
void coap_delete_cache_key (coap_cache_key_t *cache_key)
 Delete the cache-key. More...
 
coap_cache_entry_tcoap_new_cache_entry (coap_session_t *session, const coap_pdu_t *pdu, coap_cache_record_pdu_t record_pdu, coap_cache_session_based_t session_based, unsigned int idle_timeout)
 Create a new cache-entry hash keyed by cache-key derived from the PDU. More...
 
coap_cache_entry_tcoap_cache_get_by_key (coap_context_t *ctx, const coap_cache_key_t *cache_key)
 Searches for a cache-entry identified by cache_key. More...
 
coap_cache_entry_tcoap_cache_get_by_pdu (coap_session_t *session, const coap_pdu_t *request, coap_cache_session_based_t session_based)
 Searches for a cache-entry corresponding to pdu. More...
 
void coap_delete_cache_entry (coap_context_t *ctx, coap_cache_entry_t *cache_entry)
 Remove a cache-entry from the hash list and free off all the appropriate contents apart from app_data. More...
 
const coap_pdu_tcoap_cache_get_pdu (const coap_cache_entry_t *cache_entry)
 Returns the PDU information stored in the coap_cache entry. More...
 
void coap_cache_set_app_data (coap_cache_entry_t *cache_entry, void *data, coap_cache_app_data_free_callback_t callback)
 Stores data with the given cache entry. More...
 
void * coap_cache_get_app_data (const coap_cache_entry_t *cache_entry)
 Returns any application-specific data that has been stored with cache_entry using the function coap_cache_set_app_data(). More...
 
void coap_expire_cache_entries (coap_context_t *ctx)
 Expire coap_cache_entry_t entries. More...
 

Function Documentation

◆ is_cache_key()

static int is_cache_key ( uint16_t  option_type,
size_t  cache_ignore_count,
const uint16_t *  cache_ignore_options 
)
static

Definition at line 17 of file coap_cache.c.

+ Here is the caller graph for this function: