Class: GitSpelunk::Offset::Chunk::LineBlock
- Inherits:
-
Struct
- Object
- Struct
- GitSpelunk::Offset::Chunk::LineBlock
- Defined in:
- lib/git_spelunk/offset.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
Returns the value of attribute data.
-
#offset ⇒ Object
Returns the value of attribute offset.
Instance Method Summary collapse
- #<<(other) ⇒ Object
-
#initialize(offset, line) ⇒ LineBlock
constructor
A new instance of LineBlock.
- #size ⇒ Object
- #type ⇒ Object
Constructor Details
#initialize(offset, line) ⇒ LineBlock
Returns a new instance of LineBlock.
67 68 69 |
# File 'lib/git_spelunk/offset.rb', line 67 def initialize(offset, line) super(offset, [line]) end |
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data
66 67 68 |
# File 'lib/git_spelunk/offset.rb', line 66 def data @data end |
#offset ⇒ Object
Returns the value of attribute offset
66 67 68 |
# File 'lib/git_spelunk/offset.rb', line 66 def offset @offset end |
Instance Method Details
#<<(other) ⇒ Object
79 80 81 |
# File 'lib/git_spelunk/offset.rb', line 79 def <<(other) data << other end |
#size ⇒ Object
75 76 77 |
# File 'lib/git_spelunk/offset.rb', line 75 def size data.size end |
#type ⇒ Object
71 72 73 |
# File 'lib/git_spelunk/offset.rb', line 71 def type data.first.line_origin end |