• Home
  • Raw
  • Download

Lines Matching refs:ConfigParser

24 This module provides the :class:`ConfigParser` class which implements a basic
79 >>> config = configparser.ConfigParser()
103 >>> config = configparser.ConfigParser()
157 provide :meth:`~ConfigParser.getboolean`. This method is case-insensitive and
170 Apart from :meth:`~ConfigParser.getboolean`, config parsers also
171 provide equivalent :meth:`~ConfigParser.getint` and
172 :meth:`~ConfigParser.getfloat` methods. You can register your own
214 :meth:`~ConfigParser.getint`, :meth:`~ConfigParser.getfloat` and
215 :meth:`~ConfigParser.getboolean` methods, for example:
294 On top of the core functionality, :class:`ConfigParser` supports
302 The default implementation used by :class:`ConfigParser`. It enables
319 In the example above, :class:`ConfigParser` with *interpolation* set to
473 >>> parser = configparser.ConfigParser()
510 >>> config = configparser.ConfigParser(allow_no_value=True)
533 :meth:`ConfigParser.write`.
557 >>> from configparser import ConfigParser, ExtendedInterpolation
558 >>> parser = ConfigParser(interpolation=ExtendedInterpolation())
656 default :meth:`~ConfigParser.getint`, :meth:`~ConfigParser.getfloat`, and
657 :meth:`~ConfigParser.getboolean` are implemented. Should other getters be
675 .. attribute:: ConfigParser.BOOLEAN_STATES
677 By default when using :meth:`~ConfigParser.getboolean`, config parsers
685 >>> custom = configparser.ConfigParser()
698 .. method:: ConfigParser.optionxform(option)
716 >>> typical = configparser.ConfigParser()
736 .. attribute:: ConfigParser.SECTCRE
754 >>> typical = configparser.ConfigParser()
758 >>> custom = configparser.ConfigParser()
766 While ConfigParser objects also use an ``OPTCRE`` attribute for recognizing
789 # values using the mapping protocol or ConfigParser's set() does not allow
821 To get interpolation, use :class:`ConfigParser`::
825 cfg = configparser.ConfigParser()
860 config = configparser.ConfigParser({'bar': 'Life', 'baz': 'hard'})
871 ConfigParser Objects
874 .. class:: ConfigParser(defaults=None, dict_type=dict, allow_no_value=False, delimiters=('=', ':'),…
994 If none of the named files exist, the :class:`ConfigParser`
1002 config = configparser.ConfigParser()
1160 cfgparser = ConfigParser()
1209 Legacy variant of the :class:`ConfigParser`. It has interpolation
1219 Consider using :class:`ConfigParser` instead which checks types of
1221 can use ``ConfigParser(interpolation=None)``.
1238 :class:`RawConfigParser` (or :class:`ConfigParser` with *raw* parameters