libabigail
|
Namespace for handling ini-style files. More...
Classes | |
class | config |
The abstraction of the structured content of an .ini file. This roughly follows what is explained at http://en.wikipedia.org/wiki/INI_file. More... | |
class | function_call_expr |
The abstraction of a function call expression. More... | |
class | list_property |
A class representing a list property. More... | |
class | list_property_value |
Abstracts the value of a property representing a list of strings. More... | |
class | property |
The base class of the different kinds of properties of an INI file. More... | |
class | property_value |
Base class of propertie values. More... | |
class | simple_property |
A simple property. That is, one which value is a string_property_value. More... | |
class | string_property_value |
A property value which is a string. More... | |
class | tuple_property |
Abstraction of a tuple property. A tuple property is a property which value is a tuple_property_value. More... | |
class | tuple_property_value |
A property value that is a tuple. More... | |
Typedefs | |
typedef shared_ptr< config > | config_sptr |
A convenience typedef for a shared pointer to config. More... | |
typedef shared_ptr< function_call_expr > | function_call_expr_sptr |
Convenience typedef for a shared pointer to function_call_expr. More... | |
typedef shared_ptr< list_property > | list_property_sptr |
A convenience typedef for a shared_ptr to a list_property. More... | |
typedef shared_ptr< list_property_value > | list_property_value_sptr |
A convenience typedef for a shared_ptr to list_property_value. More... | |
typedef shared_ptr< property > | property_sptr |
Convenience typefef for shared_ptr to property. More... | |
typedef shared_ptr< property_value > | property_value_sptr |
Convenience typedef for a shared_ptr to property_value. More... | |
typedef shared_ptr< simple_property > | simple_property_sptr |
Convenience typedef for a shared_ptr to an simple_property. More... | |
typedef shared_ptr< string_property_value > | string_property_value_sptr |
A convenience typedef for a shared_ptr to string_property_value. More... | |
typedef shared_ptr< tuple_property > | tuple_property_sptr |
Convenience typedef for a shared_ptr of tuple_property. More... | |
typedef shared_ptr< tuple_property_value > | tuple_property_value_sptr |
Convenience typedef for a shared_ptr to a tuple_property_value. More... | |
Functions | |
list_property * | is_list_property (const property *p) |
Test if an instance of a property is actually an instance of list_property. More... | |
list_property_sptr | is_list_property (const property_sptr p) |
Test if an instance of a property is actually an instance of list_property. More... | |
list_property_value * | is_list_property_value (const property_value *v) |
Test if an instance of @property_value is a list_property_value. More... | |
list_property_value_sptr | is_list_property_value (const property_value_sptr &v) |
Test if an instance of @property_value is a list_property_value. More... | |
simple_property * | is_simple_property (const property *p) |
Tests if a property is a simple property. More... | |
simple_property_sptr | is_simple_property (const property_sptr p) |
Tests if a property is a simple property. More... | |
string_property_value * | is_string_property_value (const property_value *v) |
Test if a given property value is a string property value. More... | |
string_property_value_sptr | is_string_property_value (const property_value_sptr v) |
Test if a given property value is a string property value. More... | |
tuple_property * | is_tuple_property (const property *p) |
Test if an instance of property is an instance of tuple_property. More... | |
tuple_property_sptr | is_tuple_property (const property_sptr p) |
Test if an instance of property is an instance of tuple_property. More... | |
tuple_property_value * | is_tuple_property_value (const property_value *v) |
Test if a given instance of property_value is an instance of tuple_property_value too. More... | |
tuple_property_value_sptr | is_tuple_property_value (const property_value_sptr v) |
Test if a given instance of property_value is an instance of tuple_property_value too. More... | |
config_sptr | read_config (const string &path) |
Parse an ini config file from an on-disk file. More... | |
bool | read_config (const string &path, config &conf) |
Parse an ini config file from a file on disk. More... | |
bool | read_config (istream &input, config &conf) |
Parse an ini config file from an input stream. More... | |
config_sptr | read_config (std::istream &input) |
Parse an ini config file from an input stream. More... | |
bool | read_config (std::istream &input, config &conf) |
function_call_expr_sptr | read_function_call_expr (const string &input) |
Read a function call expression and build its representation. More... | |
bool | read_function_call_expr (const string &input, function_call_expr_sptr &expr) |
Read a function call expression and build its representation. More... | |
bool | read_function_call_expr (std::istream &input, function_call_expr_sptr &expr) |
Read a function call expression and build its representation. More... | |
bool | read_sections (const string &path, config::sections_type §ions) |
Parse the sections of an *.ini file. More... | |
bool | read_sections (std::istream &input, config::sections_type §ions) |
Parse the sections of an *.ini file. More... | |
bool | write_config (const config &conf, const string &path) |
Serialize an instance of conf to an on-disk file. More... | |
bool | write_config (const config &conf, std::ostream &output) |
Serialize an instance of config to an output stream. More... | |
bool | write_sections (const config::sections_type §ions, const string &path) |
Serialize a vector of sections that make up an ini config to a file. More... | |
bool | write_sections (const config::sections_type §ions, std::ostream &out) |
Serialize a vector of sections that make up an ini config file to an output stream. More... | |
Namespace for handling ini-style files.
typedef shared_ptr<config> config_sptr |
typedef shared_ptr<function_call_expr> function_call_expr_sptr |
Convenience typedef for a shared pointer to function_call_expr.
typedef shared_ptr<list_property> list_property_sptr |
A convenience typedef for a shared_ptr to a list_property.
typedef shared_ptr<list_property_value> list_property_value_sptr |
A convenience typedef for a shared_ptr to list_property_value.
typedef shared_ptr<property> property_sptr |
typedef shared_ptr<property_value> property_value_sptr |
Convenience typedef for a shared_ptr to property_value.
typedef shared_ptr<simple_property> simple_property_sptr |
Convenience typedef for a shared_ptr to an simple_property.
typedef shared_ptr<string_property_value> string_property_value_sptr |
A convenience typedef for a shared_ptr to string_property_value.
typedef shared_ptr<tuple_property> tuple_property_sptr |
Convenience typedef for a shared_ptr of tuple_property.
typedef shared_ptr<tuple_property_value> tuple_property_value_sptr |
Convenience typedef for a shared_ptr to a tuple_property_value.
list_property * is_list_property | ( | const property * | p | ) |
Test if an instance of a property is actually an instance of list_property.
p | the property to test. |
p
converted into a list_property if it's of type list_property, or nil otherwise. Definition at line 686 of file abg-ini.cc.
list_property_sptr is_list_property | ( | const property_sptr | p | ) |
Test if an instance of a property is actually an instance of list_property.
p | the property to test. |
p
converted into a list_property if it's of type list_property, or nil otherwise. Definition at line 697 of file abg-ini.cc.
list_property_value * is_list_property_value | ( | const property_value * | v | ) |
Test if an instance of @property_value is a list_property_value.
v | the property_value to consider. |
v
is a list_property_value, nil otherwise. Definition at line 437 of file abg-ini.cc.
list_property_value_sptr is_list_property_value | ( | const property_value_sptr & | v | ) |
Test if an instance of @property_value is a list_property_value.
v | the property_value to consider. |
v
is a list_property_value, nil otherwise. Definition at line 448 of file abg-ini.cc.
simple_property * is_simple_property | ( | const property * | p | ) |
Tests if a property is a simple property.
Definition at line 619 of file abg-ini.cc.
simple_property_sptr is_simple_property | ( | const property_sptr | p | ) |
Tests if a property is a simple property.
Definition at line 628 of file abg-ini.cc.
string_property_value * is_string_property_value | ( | const property_value * | v | ) |
Test if a given property value is a string property value.
Definition at line 341 of file abg-ini.cc.
string_property_value_sptr is_string_property_value | ( | const property_value_sptr | v | ) |
Test if a given property value is a string property value.
Definition at line 350 of file abg-ini.cc.
tuple_property * is_tuple_property | ( | const property * | p | ) |
Test if an instance of property is an instance of tuple_property.
p | the instance of property to test for. |
p
is an instance of tuple_property. Definition at line 757 of file abg-ini.cc.
tuple_property_sptr is_tuple_property | ( | const property_sptr | p | ) |
Test if an instance of property is an instance of tuple_property.
p | the instance of property to test for. |
p
is an instance of tuple_property. Definition at line 768 of file abg-ini.cc.
tuple_property_value * is_tuple_property_value | ( | const property_value * | v | ) |
Test if a given instance of property_value is an instance of tuple_property_value too.
Definition at line 525 of file abg-ini.cc.
tuple_property_value_sptr is_tuple_property_value | ( | const property_value_sptr | v | ) |
Test if a given instance of property_value is an instance of tuple_property_value too.
Definition at line 535 of file abg-ini.cc.
config_sptr read_config | ( | const string & | path | ) |
Parse an ini config file from an on-disk file.
Definition at line 1796 of file abg-ini.cc.
bool read_config | ( | const string & | path, |
config & | conf | ||
) |
Parse an ini config file from a file on disk.
path | the path to the ini file to parse. |
conf | the resulting config file to populate as a result of the parsing. This is populated iff the function returns true. |
Definition at line 1766 of file abg-ini.cc.
bool read_config | ( | istream & | input, |
config & | conf | ||
) |
Parse an ini config file from an input stream.
input | the input stream to parse the ini config file from. |
Definition at line 1747 of file abg-ini.cc.
config_sptr read_config | ( | std::istream & | input | ) |
Parse an ini config file from an input stream.
Definition at line 1782 of file abg-ini.cc.
function_call_expr_sptr read_function_call_expr | ( | const string & | input | ) |
Read a function call expression and build its representation.
input | a string where to read the function call expression from. |
Definition at line 2050 of file abg-ini.cc.
bool read_function_call_expr | ( | const string & | input, |
function_call_expr_sptr & | expr | ||
) |
Read a function call expression and build its representation.
input | a string where to read the function call expression from. |
expr | the expression resulting from the parsing. This is an output parameter that is set iff this function returns true. |
expr
is successfully set with the resulting of parsing the input
. Definition at line 2035 of file abg-ini.cc.
bool read_function_call_expr | ( | std::istream & | input, |
function_call_expr_sptr & | expr | ||
) |
Read a function call expression and build its representation.
input | the input stream where to read the function call expression from. |
expr | the expression resulting from the parsing. This is an output parameter that is set iff this function returns true. |
expr
is successfully set with the resulting of parsing the input
. Definition at line 2017 of file abg-ini.cc.
bool read_sections | ( | const string & | path, |
config::sections_type & | sections | ||
) |
Parse the sections of an *.ini file.
path | the path of the ini file to parse. |
section | out parameter. This is set to the vector of sections that have been parsed from the input stream. |
Definition at line 1728 of file abg-ini.cc.
bool read_sections | ( | std::istream & | input, |
config::sections_type & | sections | ||
) |
Parse the sections of an *.ini file.
input | the input stream to parse the ini file from. |
section | out parameter. This is set to the vector of sections that have been parsed from the input stream. |
Definition at line 1701 of file abg-ini.cc.
bool write_config | ( | const config & | conf, |
const string & | path | ||
) |
Serialize an instance of conf to an on-disk file.
conf | the instance of config to serialize. |
path | the path to the on-disk file to serialize to. |
Definition at line 1943 of file abg-ini.cc.
bool write_config | ( | const config & | conf, |
std::ostream & | output | ||
) |
Serialize an instance of config to an output stream.
conf | the instance of config to serialize. |
output | the output stream to serialize conf to. |
Definition at line 1927 of file abg-ini.cc.
bool write_sections | ( | const config::sections_type & | sections, |
const string & | path | ||
) |
Serialize a vector of sections that make up an ini config to a file.
sections | the vector of sections to serialize. |
out | the output stream. |
Definition at line 1904 of file abg-ini.cc.
bool write_sections | ( | const config::sections_type & | sections, |
std::ostream & | out | ||
) |
Serialize a vector of sections that make up an ini config file to an output stream.
Note that an ini config is just a collection of sections.
sections | the vector of sections to serialize. |
out | the output stream. |
Definition at line 1882 of file abg-ini.cc.