summaryrefslogtreecommitdiffstats
path: root/Lib/multifile.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/multifile.py')
-rw-r--r--Lib/multifile.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/Lib/multifile.py b/Lib/multifile.py
index 7a52ab6..71e0dd0 100644
--- a/Lib/multifile.py
+++ b/Lib/multifile.py
@@ -85,6 +85,17 @@ class MultiFile:
err('*** Missing endmarker in MultiFile.readline()\n')
return ''
#
+ def readlines(self):
+ list = []
+ while 1:
+ line = self.readline()
+ if not line: break
+ list.append(line)
+ return list
+ #
+ def read(self): # Note: no size argument -- read until EOF only!
+ return string.joinfields(self.readlines(), '')
+ #
def next(self):
while self.readline(): pass
if self.level > 1 or self.last: