Class: Omnizip::Formats::Xz::Entry
- Inherits:
-
Object
- Object
- Omnizip::Formats::Xz::Entry
- Defined in:
- lib/omnizip/formats/xz/reader.rb
Overview
Entry class for extract API compatibility XZ format is a single stream, so this is a simple wrapper
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
Instance Method Summary collapse
-
#initialize(data) ⇒ Entry
constructor
A new instance of Entry.
-
#read ⇒ String
Read the decompressed data.
-
#size ⇒ Integer
(also: #bytesize)
Get data size.
Constructor Details
#initialize(data) ⇒ Entry
Returns a new instance of Entry.
96 97 98 |
# File 'lib/omnizip/formats/xz/reader.rb', line 96 def initialize(data) @data = data end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
94 95 96 |
# File 'lib/omnizip/formats/xz/reader.rb', line 94 def data @data end |
Instance Method Details
#read ⇒ String
Read the decompressed data
103 104 105 |
# File 'lib/omnizip/formats/xz/reader.rb', line 103 def read @data end |
#size ⇒ Integer Also known as: bytesize
Get data size
110 111 112 |
# File 'lib/omnizip/formats/xz/reader.rb', line 110 def size @data.bytesize end |