From d5e2e42f21298a9b5fd0e1ddb3639330db067caf Mon Sep 17 00:00:00 2001 From: Philip Eisenlohr Date: Fri, 22 Aug 2014 15:37:46 +0000 Subject: [PATCH] file handle closing can now be done from within class. methods: .input_close() .output_close() --- lib/damask/asciitable.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/damask/asciitable.py b/lib/damask/asciitable.py index c082739fa..f6fdab056 100644 --- a/lib/damask/asciitable.py +++ b/lib/damask/asciitable.py @@ -43,6 +43,10 @@ class ASCIItable(): except: return 0.0 +# ------------------------------------------------------------------ + def input_close(self): + return self.__IO__['in'].close() + # ------------------------------------------------------------------ def output_write(self, what): @@ -73,6 +77,10 @@ class ASCIItable(): def output_clear(self): self.__IO__['output'] = [] +# ------------------------------------------------------------------ + def output_close(self): + return self.__IO__['out'].close() + # ------------------------------------------------------------------ def head_read(self): '''