Delta Chat Core C-API
Public Member Functions | List of all members
mrlot_t Class Reference

An object containing a set of values. More...

#include <mrlot.h>

Public Member Functions

void mrlot_unref (mrlot_t *set)
 Frees an object containing a set of parameters. More...
 
char * mrlot_get_text1 (mrlot_t *lot)
 Get first string. More...
 
char * mrlot_get_text2 (mrlot_t *lot)
 Get second string. More...
 
int mrlot_get_text1_meaning (mrlot_t *lot)
 Get the meaning of the first string. More...
 
int mrlot_get_state (mrlot_t *lot)
 Get the associated state. More...
 
time_t mrlot_get_timestamp (mrlot_t *lot)
 Get the associated timestamp. More...
 

Detailed Description

An object containing a set of values.

The meaning of the values is defined by the function returning the set object. Set objects are created eg. by mrchatlist_get_summary(), mrmsg_get_summary() or by mrmsg_get_mediainfo().

NB: Lot is used in the meaning heap here.

Member Function Documentation

void mrlot_unref ( mrlot_t set)

Frees an object containing a set of parameters.

If the set object contains strings, the strings are also freed with this function. Set objects are created eg. by mrchatlist_get_summary(), mrmsg_get_summary or by mrmsg_get_mediainfo().

Parameters
setThe object to free.
Returns
None
char * mrlot_get_text1 ( mrlot_t lot)

Get first string.

The meaning of the string is defined by the creator or the object any may be roughly described by mrlot_get_text1_meaning().

Parameters
lotThe lot object.
Returns
A string, the string may be empty and the returned value must be free()'d. NULL if there is no such string.
char * mrlot_get_text2 ( mrlot_t lot)

Get second string.

The meaning of the string is defined by the creator or the object.

Parameters
lotThe lot object.
Returns
A string, the string may be empty and the returned value must be free()'d . NULL if there is no such string.
int mrlot_get_text1_meaning ( mrlot_t lot)

Get the meaning of the first string.

Posssible meanings of the string are defined by the creator or the object and may be returned eg. as MR_TEXT1_DRAFT, MR_TEXT1_USERNAME or MR_TEXT1_SELF.

Parameters
lotThe lot object.
Returns
Returns the meaning of the first string, possible meanings are defined by the creator of the object. 0 if there is no concrete meaning or on errors.
int mrlot_get_state ( mrlot_t lot)

Get the associated state.

The meaning of the state is defined by the creator or the object.

Parameters
lotThe lot object.
Returns
The state as defined by the creator of the object. 0 if there is not state or on errors.
time_t mrlot_get_timestamp ( mrlot_t lot)

Get the associated timestamp.

The meaning of the timestamp is defined by the creator or the object.

Parameters
lotThe lot object.
Returns
The timestamp as defined by the creator of the object. 0 if there is not timestamp or on errors.

The documentation for this class was generated from the following files: