FreeRDP
settings_getters.c File Reference
#include <winpr/assert.h>
#include <freerdp/settings.h>
#include <freerdp/log.h>
#include "../core/settings.h"

Macros

#define TAG   FREERDP_TAG("common.settings")
 

Functions

static void free_string (char **current, BOOL cleanup)
 
static BOOL alloc_empty_string (char **current, const char *next, size_t next_len)
 
static BOOL update_string_copy_ (char **current, const char *next, size_t next_len, BOOL cleanup)
 
static BOOL update_string_ (char **current, char *next, size_t next_len)
 
BOOL freerdp_settings_get_bool (const rdpSettings *settings, size_t id)
 Returns a boolean settings value. More...
 
BOOL freerdp_settings_set_bool (rdpSettings *settings, size_t id, BOOL val)
 Sets a BOOL settings value. More...
 
UINT16 freerdp_settings_get_uint16 (const rdpSettings *settings, size_t id)
 Returns a UINT16 settings value. More...
 
BOOL freerdp_settings_set_uint16 (rdpSettings *settings, size_t id, UINT16 val)
 Sets a UINT16 settings value. More...
 
INT16 freerdp_settings_get_int16 (const rdpSettings *settings, size_t id)
 Returns a INT16 settings value. More...
 
BOOL freerdp_settings_set_int16 (rdpSettings *settings, size_t id, INT16 val)
 Sets a INT16 settings value. More...
 
UINT32 freerdp_settings_get_uint32 (const rdpSettings *settings, size_t id)
 Returns a UINT32 settings value. More...
 
BOOL freerdp_settings_set_uint32 (rdpSettings *settings, size_t id, UINT32 val)
 Sets a UINT32 settings value. More...
 
INT32 freerdp_settings_get_int32 (const rdpSettings *settings, size_t id)
 Returns a INT32 settings value. More...
 
BOOL freerdp_settings_set_int32 (rdpSettings *settings, size_t id, INT32 val)
 Sets a INT32 settings value. More...
 
UINT64 freerdp_settings_get_uint64 (const rdpSettings *settings, size_t id)
 Returns a UINT64 settings value. More...
 
BOOL freerdp_settings_set_uint64 (rdpSettings *settings, size_t id, UINT64 val)
 Sets a UINT64 settings value. More...
 
INT64 freerdp_settings_get_int64 (const rdpSettings *settings, size_t id)
 Returns a INT64 settings value. More...
 
BOOL freerdp_settings_set_int64 (rdpSettings *settings, size_t id, INT64 val)
 Sets a INT64 settings value. More...
 
const char * freerdp_settings_get_string (const rdpSettings *settings, size_t id)
 Returns a immutable string settings value. More...
 
char * freerdp_settings_get_string_writable (rdpSettings *settings, size_t id)
 Returns a string settings value. More...
 
BOOL freerdp_settings_set_string_ (rdpSettings *settings, size_t id, char *val, size_t len)
 
BOOL freerdp_settings_set_string_len (rdpSettings *settings, size_t id, const char *val, size_t len)
 Sets a string settings value. The param is copied. More...
 
BOOL freerdp_settings_set_string (rdpSettings *settings, size_t id, const char *val)
 Sets a string settings value. The param is copied. More...
 
BOOL freerdp_settings_set_string_copy_ (rdpSettings *settings, size_t id, const char *val, size_t len, BOOL cleanup)
 
void * freerdp_settings_get_pointer_writable (rdpSettings *settings, size_t id)
 Returns a mutable pointer settings value. More...
 
BOOL freerdp_settings_set_pointer (rdpSettings *settings, size_t id, const void *val)
 

Macro Definition Documentation

◆ TAG

#define TAG   FREERDP_TAG("common.settings")

Function Documentation

◆ alloc_empty_string()

static BOOL alloc_empty_string ( char **  current,
const char *  next,
size_t  next_len 
)
static
Here is the caller graph for this function:

◆ free_string()

static void free_string ( char **  current,
BOOL  cleanup 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_get_bool()

BOOL freerdp_settings_get_bool ( const rdpSettings *  settings,
size_t  id 
)

Returns a boolean settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the boolean key
Here is the call graph for this function:

◆ freerdp_settings_get_int16()

INT16 freerdp_settings_get_int16 ( const rdpSettings *  settings,
size_t  id 
)

Returns a INT16 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the INT16 key
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_get_int32()

INT32 freerdp_settings_get_int32 ( const rdpSettings *  settings,
size_t  id 
)

Returns a INT32 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the INT32 key
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_get_int64()

INT64 freerdp_settings_get_int64 ( const rdpSettings *  settings,
size_t  id 
)

Returns a INT64 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the INT64 key
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_get_pointer_writable()

void* freerdp_settings_get_pointer_writable ( rdpSettings *  settings,
size_t  id 
)

Returns a mutable pointer settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the mutable pointer value
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_get_string()

const char* freerdp_settings_get_string ( const rdpSettings *  settings,
size_t  id 
)

Returns a immutable string settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the immutable string pointer
Here is the call graph for this function:

◆ freerdp_settings_get_string_writable()

char* freerdp_settings_get_string_writable ( rdpSettings *  settings,
size_t  id 
)

Returns a string settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the string pointer
Here is the call graph for this function:

◆ freerdp_settings_get_uint16()

UINT16 freerdp_settings_get_uint16 ( const rdpSettings *  settings,
size_t  id 
)

Returns a UINT16 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the UINT16 key
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_get_uint32()

UINT32 freerdp_settings_get_uint32 ( const rdpSettings *  settings,
size_t  id 
)

Returns a UINT32 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the UINT32 key
Here is the call graph for this function:

◆ freerdp_settings_get_uint64()

UINT64 freerdp_settings_get_uint64 ( const rdpSettings *  settings,
size_t  id 
)

Returns a UINT64 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
Returns
the value of the UINT64 key
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_bool()

BOOL freerdp_settings_set_bool ( rdpSettings *  settings,
size_t  id,
BOOL  param 
)

Sets a BOOL settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:

◆ freerdp_settings_set_int16()

BOOL freerdp_settings_set_int16 ( rdpSettings *  settings,
size_t  id,
INT16  param 
)

Sets a INT16 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_int32()

BOOL freerdp_settings_set_int32 ( rdpSettings *  settings,
size_t  id,
INT32  param 
)

Sets a INT32 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_int64()

BOOL freerdp_settings_set_int64 ( rdpSettings *  settings,
size_t  id,
INT64  param 
)

Sets a INT64 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_pointer()

BOOL freerdp_settings_set_pointer ( rdpSettings *  settings,
size_t  id,
const void *  val 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_string()

BOOL freerdp_settings_set_string ( rdpSettings *  settings,
size_t  id,
const char *  param 
)

Sets a string settings value. The param is copied.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set. If NULL removes the old entry, otherwise a copy is created.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_string_()

BOOL freerdp_settings_set_string_ ( rdpSettings *  settings,
size_t  id,
char *  val,
size_t  len 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_string_copy_()

BOOL freerdp_settings_set_string_copy_ ( rdpSettings *  settings,
size_t  id,
const char *  val,
size_t  len,
BOOL  cleanup 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_string_len()

BOOL freerdp_settings_set_string_len ( rdpSettings *  settings,
size_t  id,
const char *  param,
size_t  len 
)

Sets a string settings value. The param is copied.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set. If NULL allocates an empty string buffer of len size, otherwise a copy is created.
lenThe length of param, 0 to remove the old entry.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_uint16()

BOOL freerdp_settings_set_uint16 ( rdpSettings *  settings,
size_t  id,
UINT16  param 
)

Sets a UINT16 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_settings_set_uint32()

BOOL freerdp_settings_set_uint32 ( rdpSettings *  settings,
size_t  id,
UINT32  param 
)

Sets a UINT32 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:

◆ freerdp_settings_set_uint64()

BOOL freerdp_settings_set_uint64 ( rdpSettings *  settings,
size_t  id,
UINT64  param 
)

Sets a UINT64 settings value.

Parameters
settingsA pointer to the settings to query, must not be NULL.
idThe key to query
paramThe value to set.
Returns
TRUE for success, FALSE for failure
Here is the call graph for this function:
Here is the caller graph for this function:

◆ update_string_()

static BOOL update_string_ ( char **  current,
char *  next,
size_t  next_len 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ update_string_copy_()

static BOOL update_string_copy_ ( char **  current,
const char *  next,
size_t  next_len,
BOOL  cleanup 
)
static
Here is the call graph for this function:
Here is the caller graph for this function: