◆ contains_pre_key
int(* signal_protocol_pre_key_store::contains_pre_key) (uint32_t pre_key_id, void *user_data) |
Determine whether there is a committed PreKey record matching the provided ID.
- Parameters
-
pre_key_id | A PreKey record ID. |
- Returns
- 1 if the store has a record for the PreKey ID, 0 otherwise
◆ destroy_func
void(* signal_protocol_pre_key_store::destroy_func) (void *user_data) |
Function called to perform cleanup when the data store context is being destroyed.
◆ load_pre_key
int(* signal_protocol_pre_key_store::load_pre_key) (signal_buffer **record, uint32_t pre_key_id, void *user_data) |
Load a local serialized PreKey record.
- Parameters
-
record | pointer to a newly allocated buffer containing the record, if found. Unset if no record was found. The Signal Protocol library is responsible for freeing this buffer. |
pre_key_id | the ID of the local serialized PreKey record |
- Return values
-
SG_SUCCESS | if the key was found |
SG_ERR_INVALID_KEY_ID | if the key could not be found |
◆ remove_pre_key
int(* signal_protocol_pre_key_store::remove_pre_key) (uint32_t pre_key_id, void *user_data) |
Delete a PreKey record from local storage.
- Parameters
-
pre_key_id | The ID of the PreKey record to remove. |
- Returns
- 0 on success, negative on failure
◆ store_pre_key
int(* signal_protocol_pre_key_store::store_pre_key) (uint32_t pre_key_id, uint8_t *record, size_t record_len, void *user_data) |
Store a local serialized PreKey record.
- Parameters
-
pre_key_id | the ID of the PreKey record to store. |
record | pointer to a buffer containing the serialized record |
record_len | length of the serialized record |
- Returns
- 0 on success, negative on failure
◆ user_data
void* signal_protocol_pre_key_store::user_data |
The documentation for this struct was generated from the following file: