![]() |
libgpac
Documentation of the core library of GPAC
|
Configuration File object. More...
Collaboration diagram for Configuration File:Functions | |
| GF_Config * | gf_cfg_new (const char *filePath, const char *fileName) |
| configuration file constructor | |
| GF_Config * | gf_cfg_force_new (const char *filePath, const char *fileName) |
| alternative configuration file constructor | |
| void | gf_cfg_del (GF_Config *cfgFile) |
| configuration file destructor | |
| void | gf_cfg_remove (GF_Config *cfgFile) |
| configuration file destructor | |
| GF_Err | gf_cfg_save (GF_Config *cfgFile) |
| configuration saving | |
| const char * | gf_cfg_get_key (GF_Config *cfgFile, const char *secName, const char *keyName) |
| key value query | |
| GF_Err | gf_cfg_set_key (GF_Config *cfgFile, const char *secName, const char *keyName, const char *keyValue) |
| key value update | |
| u32 | gf_cfg_get_section_count (GF_Config *cfgFile) |
| section count query | |
| const char * | gf_cfg_get_section_name (GF_Config *cfgFile, u32 secIndex) |
| section name query | |
| u32 | gf_cfg_get_key_count (GF_Config *cfgFile, const char *secName) |
| key count query | |
| const char * | gf_cfg_get_key_name (GF_Config *cfgFile, const char *secName, u32 keyIndex) |
| key count query | |
| void | gf_cfg_del_section (GF_Config *cfgFile, const char *secName) |
| section destrouction | |
| const char * | gf_cfg_get_filename (GF_Config *iniFile) |
| GF_Err | gf_cfg_discard_changes (GF_Config *iniFile) |
Configuration File object.
This section documents the configuration file objects of the GPAC framework. A specific global configuration file is used for libgpac, see Library configuration. Such objects may be used by third-party applications to store data, and are used by the player scripting API to store various GUI data. A configuration file is formatted as the INI file mode of WIN32 in sections and keys.
| GF_Config * gf_cfg_new | ( | const char * | filePath, |
| const char * | fileName | ||
| ) |
configuration file constructor
Constructs a configuration file.
| filePath | directory the file is located in |
| fileName | name of the configuration file |
Here is the call graph for this function:
Here is the caller graph for this function:| GF_Config * gf_cfg_force_new | ( | const char * | filePath, |
| const char * | fileName | ||
| ) |
alternative configuration file constructor
Constructs a configuration file. If file does not exist, configuration will be still created
| filePath | directory the file is located in |
| fileName | name of the configuration file |
Here is the call graph for this function:
Here is the caller graph for this function:| void gf_cfg_del | ( | GF_Config * | cfgFile | ) |
configuration file destructor
Destroys the configuration file and saves it if needed.
| cfgFile | the target configuration file |
Here is the call graph for this function:
Here is the caller graph for this function:| void gf_cfg_remove | ( | GF_Config * | cfgFile | ) |
configuration file destructor
Destroys the configuration file and removes the file from disk.
| cfgFile | the target configuration file |
| GF_Err gf_cfg_save | ( | GF_Config * | cfgFile | ) |
configuration saving
Saves the configuration file if modified.
| cfgFile | the target configuration file |
Here is the call graph for this function:
Here is the caller graph for this function:| const char * gf_cfg_get_key | ( | GF_Config * | cfgFile, |
| const char * | secName, | ||
| const char * | keyName | ||
| ) |
key value query
Gets a key value from its section and name.
| cfgFile | the target configuration file |
| secName | the desired key parent section name |
| keyName | the desired key name |
Here is the call graph for this function:
Here is the caller graph for this function:| GF_Err gf_cfg_set_key | ( | GF_Config * | cfgFile, |
| const char * | secName, | ||
| const char * | keyName, | ||
| const char * | keyValue | ||
| ) |
key value update
Sets a key value from its section and name.
| cfgFile | the target configuration file |
| secName | the desired key parent section name |
| keyName | the desired key name |
| keyValue | the desired key value |
Here is the call graph for this function:
Here is the caller graph for this function:| u32 gf_cfg_get_section_count | ( | GF_Config * | cfgFile | ) |
section count query
Gets the number of sections in the configuration file
| cfgFile | the target configuration file |
Here is the call graph for this function:
Here is the caller graph for this function:| const char * gf_cfg_get_section_name | ( | GF_Config * | cfgFile, |
| u32 | secIndex | ||
| ) |
section name query
Gets a section name based on its index
| cfgFile | the target configuration file |
| secIndex | 0-based index of the section to query |
Here is the call graph for this function:
Here is the caller graph for this function:| u32 gf_cfg_get_key_count | ( | GF_Config * | cfgFile, |
| const char * | secName | ||
| ) |
key count query
Gets the number of keys in a section of the configuration file
| cfgFile | the target configuration file |
| secName | the target section |
Here is the call graph for this function:
Here is the caller graph for this function:| const char * gf_cfg_get_key_name | ( | GF_Config * | cfgFile, |
| const char * | secName, | ||
| u32 | keyIndex | ||
| ) |
key count query
Gets the number of keys in a section of the configuration file
| cfgFile | the target configuration file |
| secName | the target section |
| keyIndex | 0-based index of the key in the section |
Here is the call graph for this function:
Here is the caller graph for this function:| void gf_cfg_del_section | ( | GF_Config * | cfgFile, |
| const char * | secName | ||
| ) |
section destrouction
Removes all entries in the given section
| cfgFile | the target configuration file |
| secName | the target section |
Here is the call graph for this function:
Here is the caller graph for this function:| const char * gf_cfg_get_filename | ( | GF_Config * | iniFile | ) |
Get the full filename associated with this config file
| iniFile | The Configuration |
Here is the caller graph for this function:| GF_Err gf_cfg_discard_changes | ( | GF_Config * | iniFile | ) |
Do not save results to file
| iniFile | The Configuration |
Here is the caller graph for this function: