- Project tools
-
-
- How do I...
-
| Category |
Featured projects |
| scm |
Subversion,
Subclipse,
TortoiseSVN,
RapidSVN
|
| issuetrack |
Scarab |
| requirements |
xmlbasedsrs |
| design |
ArgoUML |
| techcomm |
SubEtha,
eyebrowse,
midgard,
cowiki |
| construction |
antelope,
scons,
frameworx,
build-interceptor,
propel,
phing
|
| testing |
maxq,
aut
|
| deployment |
current |
| process |
ReadySET |
| libraries |
GEF,
Axion,
Style,
SSTree
|
| Over 500 more tools... |
|
Welcome to the new Tigris! There have been some changes to the administration of mail lists. Project and list owners should check out the Discussion Services release notes.
|
Module ConfigParser ::
Class ConfigParser
|
|
Class ConfigParser
RawConfigParser --+
|
ConfigParser
- Known Subclasses:
-
CmConfigParser
| Method Summary |
| |
get(self,
section,
option,
raw,
vars)
Get an option value for a given section. |
| |
items(self,
section,
raw,
vars)
Return a list of tuples with (name, value) for each option in the
section. |
| |
_interpolate(self,
section,
option,
rawval,
vars)
|
| |
_interpolation_replace(self,
match)
|
| Inherited from RawConfigParser |
| |
__init__(self,
defaults)
|
| |
add_section(self,
section)
Create a new section in the configuration. |
| |
defaults(self)
|
| |
getboolean(self,
section,
option)
|
| |
getfloat(self,
section,
option)
|
| |
getint(self,
section,
option)
|
| |
has_option(self,
section,
option)
Check for the existence of a given option in a given section. |
| |
has_section(self,
section)
Indicate whether the named section is present in the
configuration. |
| |
options(self,
section)
Return a list of option names for the given section name. |
| |
optionxform(self,
optionstr)
|
| |
read(self,
filenames)
Read and parse a filename or a list of filenames. |
| |
readfp(self,
fp,
filename)
Like read() but the argument must be a file-like object. |
| |
remove_option(self,
section,
option)
Remove an option. |
| |
remove_section(self,
section)
Remove a file section. |
| |
sections(self)
Return a list of section names, excluding [DEFAULT] |
| |
set(self,
section,
option,
value)
Set an option. |
| |
write(self,
fp)
Write an .ini-format representation of the configuration state. |
| |
_get(self,
section,
conv,
option)
|
| |
_read(self,
fp,
fpname)
Parse a sectioned setup file. |
| Class Variable Summary |
SRE_Pattern |
_KEYCRE = %\(([^\)]*)\)s|.
|
| Inherited from RawConfigParser |
SRE_Pattern |
OPTCRE = ([^:=\s][^:=]*)\s*([:=])\s*(.*)$
|
SRE_Pattern |
SECTCRE = \[([^\]]+)\]
|
dict |
_boolean_states = {'on': True, 'false': False, 'no': Fal...
|
get(self,
section,
option,
raw=False,
vars=None)
Get an option value for a given section.
All % interpolations are expanded in the return values, based on the
defaults passed into the constructor, unless the optional argument
`raw' is true. Additional substitutions may be provided using the
`vars' argument, which must be a dictionary whose contents overrides
any pre-existing defaults.
The section DEFAULT is special.
-
- Overrides:
ConfigParser.RawConfigParser.get
|
items(self,
section,
raw=False,
vars=None)
Return a list of tuples with (name, value) for each option in the
section.
All % interpolations are expanded in the return values, based on the
defaults passed into the constructor, unless the optional argument
`raw' is true. Additional substitutions may be provided using the
`vars' argument, which must be a dictionary whose contents overrides
any pre-existing defaults.
The section DEFAULT is special.
-
- Overrides:
ConfigParser.RawConfigParser.items
|
_KEYCRE
-
- Type:
-
SRE_Pattern
- Value:
|
|