rpki.config.parser Class Reference
Inherits object.
List of all members.
Detailed Description
Extensions to stock Python ConfigParser:
Read config file and set default section while initializing parser object.
Support for OpenSSL-style subscripted options and a limited form of
OpenSSL-style indirect variable references (${section::option}).
get-methods with default values and default section name.
Definition at line 38 of file config.py.
Member Function Documentation
def rpki.config.parser.__init__ |
( |
|
self, |
|
|
|
filename, |
|
|
|
section = None , |
|
|
|
allow_missing = False | |
|
) |
| | |
def rpki.config.parser._repl |
( |
|
self, |
|
|
|
m | |
|
) |
| | [private] |
Replacement function for indirect variable substitution.
This is intended for use with re.subn().
Definition at line 101 of file config.py.
def rpki.config.parser.get |
( |
|
self, |
|
|
|
option, |
|
|
|
default = None , |
|
|
|
section = None | |
|
) |
| | |
Get an option, perhaps with a default value.
Definition at line 112 of file config.py.
def rpki.config.parser.getboolean |
( |
|
self, |
|
|
|
option, |
|
|
|
default = None , |
|
|
|
section = None | |
|
) |
| | |
Get a boolean option, perhaps with a default value.
Definition at line 126 of file config.py.
def rpki.config.parser.getint |
( |
|
self, |
|
|
|
option, |
|
|
|
default = None , |
|
|
|
section = None | |
|
) |
| | |
Get an integer option, perhaps with a default value.
Definition at line 138 of file config.py.
def rpki.config.parser.getlong |
( |
|
self, |
|
|
|
option, |
|
|
|
default = None , |
|
|
|
section = None | |
|
) |
| | |
Get a long integer option, perhaps with a default value.
Definition at line 144 of file config.py.
def rpki.config.parser.has_option |
( |
|
self, |
|
|
|
option, |
|
|
|
section = None | |
|
) |
| | |
Test whether an option exists.
Definition at line 71 of file config.py.
def rpki.config.parser.has_section |
( |
|
self, |
|
|
|
section | |
|
) |
| | |
Test whether a section exists.
Definition at line 64 of file config.py.
def rpki.config.parser.multiget |
( |
|
self, |
|
|
|
option, |
|
|
|
section = None | |
|
) |
| | |
Parse OpenSSL-style foo.0, foo.1, ... subscripted options.
Returns a list of values matching the specified option name.
Definition at line 80 of file config.py.
def rpki.config.parser.set_global_flags |
( |
|
self |
) |
|
Consolidated control for all the little global control flags
scattered through the libraries. This isn't a particularly good
place for this function to live, but it has to live somewhere and
making it a method of the config parser from which it gets all of
its data is less silly than the available alternatives.
Definition at line 150 of file config.py.
Member Data Documentation
The documentation for this class was generated from the following file: