ewatercycle.parametersetdb.config module

class ewatercycle.parametersetdb.config.CaseConfigParser(defaults=None, dict_type=<class 'collections.OrderedDict'>, allow_no_value=False, *, delimiters=('=', ':'), comment_prefixes=('#', ';'), inline_comment_prefixes=None, strict=True, empty_lines_in_values=True, default_section='DEFAULT', interpolation=<object object>, converters=<object object>)

Bases: ConfigParser

Case sensitive config parser See https://stackoverflow.com/questions/1611799/preserve-case-in-configparser

optionxform(optionstr)
ewatercycle.parametersetdb.config.fetch(url)

Fetches text of url

class ewatercycle.parametersetdb.config.AbstractConfig(source: str)

Bases: ABC

config: Any

Dict like content of config

abstract save(target: str)
Parameters

target – File path to save config to

Returns:

class ewatercycle.parametersetdb.config.IniConfig(source)

Bases: AbstractConfig

Config container where config is read/saved in ini format.

config: Any

Dict like content of config

save(target)
Parameters

target – File path to save config to

Returns:

class ewatercycle.parametersetdb.config.YamlConfig(source)

Bases: AbstractConfig

Config container where config is read/saved in yaml format

yaml = <ruamel.yaml.main.YAML object>
config: Any

Dict like content of config

save(target)
Parameters

target – File path to save config to

Returns:

class ewatercycle.parametersetdb.config.XmlConfig(source)

Bases: AbstractConfig

Config container where config is read/saved in xml format.

config: Any

XML element used to make changes to the config

save(target)

Save xml to file.

Parameters

target – file to save to