Class: Omnizip::Formats::Rar::Compression::LZ77Huffman::MatchFinder::Match

Inherits:
Object
  • Object
show all
Defined in:
lib/omnizip/formats/rar/compression/lz77_huffman/match_finder.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(offset, length) ⇒ Match

Returns a new instance of Match.



18
19
20
21
# File 'lib/omnizip/formats/rar/compression/lz77_huffman/match_finder.rb', line 18

def initialize(offset, length)
  @offset = offset
  @length = length
end

Instance Attribute Details

#lengthObject (readonly)

Returns the value of attribute length.



16
17
18
# File 'lib/omnizip/formats/rar/compression/lz77_huffman/match_finder.rb', line 16

def length
  @length
end

#offsetObject (readonly)

Returns the value of attribute offset.



16
17
18
# File 'lib/omnizip/formats/rar/compression/lz77_huffman/match_finder.rb', line 16

def offset
  @offset
end

Instance Method Details

#==(other) ⇒ Object



23
24
25
# File 'lib/omnizip/formats/rar/compression/lz77_huffman/match_finder.rb', line 23

def ==(other)
  offset == other.offset && length == other.length
end