class Config_Collection:
Method | __init__ |
Initializes a config collection: A list of groups (dictionaries). |
Method | add_group |
Appends a group to the collection. |
Method | del_group |
Deletes a group from the collection. |
Method | get_all_groups |
Gets every group in the collection. |
Method | get_count |
Gets the number of groups in the collection. |
Method | get_group |
Gets a group from the collection. |
Method | set |
Sets a value for some key in a group of the collection. |
Instance Variable | first_without_suffix |
Undocumented |
Instance Variable | gui |
Undocumented |
Instance Variable | prefix |
Undocumented |
Instance Variable | types |
Undocumented |
Method | _get_suffix |
Gets the suffix for a given group index. |
Initializes a config collection: A list of groups (dictionaries).
Example for the SOMETHING collection, consisting of two groups _0 and _1, each with two keys FOO and BAR: SOMETHING_count = 2 SOMETHING_FOO_0 = "1st value in 1st group" SOMETHING_BAR_0 = "2nd value in 1st group" SOMETHING_FOO_1 = "1st value in 2nd group" SOMETHING_BAR_1 = "2nd value in 2nd group"
Parameters | |
gui:GUI | GUI |
prefix:str | Prefix |
types:Dict | Key:Type (Dictionary) |
first_without_suffix:bool | Enable to omit the suffix "_0" for the first group |
Parameters | |
values:Optional[ | Key:Value (Dictionary) |
Parameters | |
group_index:int | Group index |
Returns | |
List[ | List of groups (dictionaries) |
Returns | |
int | Number of groups in the collection |
Parameters | |
group_index:int | Group index |
Returns | |
Dict | Group (dictionary) |