]> git.donarmstrong.com Git - biopieces.git/blobdiff - code_ruby/lib/maasha/filesys.rb
added hacky thing to avoid warning from zlib
[biopieces.git] / code_ruby / lib / maasha / filesys.rb
index 00530d655720eaa7e82f51f6ece33353527ae8d8..e842178853a6f79d9aab4df1239c7a5908c7a6fa 100644 (file)
@@ -65,15 +65,22 @@ class Filesys
     end
   end
 
-  # TODO figure out what type is for.
-  def initialize(io, type=nil)
-    @io   = io
-    @type = type
+  def initialize(io)
+    @io = io
   end
 
   # Method to close ios.
   def close
-    @io.close
+    @io.close unless @io.is_a? Zlib::GzipReader
+  end
+
+  def eof?
+    @io.eof?
+  end
+
+  # Method to check if io is closed.
+  def closed?
+    @io.closed?
   end
 
   # Iterator method for parsing entries.