Mercurial > hgrepos > Python > libs > ConfigMix
comparison configmix/ini.py @ 150:0ac6ffae969f
FIX: Docu for INIConfigParser.read_file
| author | Franz Glasner <hg@dom66.de> |
|---|---|
| date | Sat, 14 Apr 2018 12:54:54 +0200 |
| parents | 614a0a648f48 |
| children | c46b0f82922a |
comparison
equal
deleted
inserted
replaced
| 149:614a0a648f48 | 150:0ac6ffae969f |
|---|---|
| 74 raise NotImplementedError("use `read_file()' instead") | 74 raise NotImplementedError("use `read_file()' instead") |
| 75 | 75 |
| 76 def read_file(self, fp, filename): | 76 def read_file(self, fp, filename): |
| 77 """Read from a file-like object `fp`. | 77 """Read from a file-like object `fp`. |
| 78 | 78 |
| 79 The `fp` argument must have a `readline()` method. | 79 The `fp` argument must be iterable. |
| 80 | 80 |
| 81 """ | 81 """ |
| 82 if hasattr(self, "filename"): | 82 if hasattr(self, "filename"): |
| 83 raise RuntimeError("already initialized") | 83 raise RuntimeError("already initialized") |
| 84 filename = os.path.normpath(os.path.abspath(filename)) | 84 filename = os.path.normpath(os.path.abspath(filename)) |
