Class: ZipList
Overview
:nodoc:all
Instance Method Summary (collapse)
- - (Object) get_input_stream(entry, &aProc)
-
- (ZipList) initialize(zipFileList)
constructor
A new instance of ZipList.
Constructor Details
- (ZipList) initialize(zipFileList)
A new instance of ZipList
33 34 35 |
# File 'lib/zip/ziprequire.rb', line 33 def initialize(zipFileList) @zipFileList = zipFileList end |
Instance Method Details
- (Object) get_input_stream(entry, &aProc)
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/zip/ziprequire.rb', line 37 def get_input_stream(entry, &aProc) @zipFileList.each { |zfName| Zip::ZipFile.open(zfName) { |zf| begin return zf.get_input_stream(entry, &aProc) rescue Errno::ENOENT end } } raise Errno::ENOENT, "No matching entry found in zip files '#{@zipFileList.join(', ')}' "+ " for '#{entry}'" end |