Module: RepomdParser
- Defined in:
- lib/repomd_parser/version.rb,
lib/repomd_parser.rb
Overview
repomd_parser – Ruby gem to parse RPM repository metadata Copyright © 2018 Ivan Kapelyukhin, SUSE Linux GmbH
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
Defined Under Namespace
Classes: BaseParser, DeltainfoXmlParser, PrimaryXmlParser, Reference, RepomdXmlParser, ZstdReader
Constant Summary collapse
- VERSION =
'1.3.0'.freeze
Class Method Summary collapse
Class Method Details
.decompress_io(io_object, filename) ⇒ Object
31 32 33 34 35 36 37 38 39 |
# File 'lib/repomd_parser.rb', line 31 def self.decompress_io(io_object, filename) case File.extname(filename) when '.gz' then Zlib::GzipReader.new(io_object) when '.zst' then RepomdParser::ZstdReader.new(io_object) when '.bz2' then Bzip2::FFI::Reader.open(io_object) when '.xz' then XZ::StreamReader.open(io_object) else io_object end end |