Class: Xberg::DiffLineAdded

Inherits:
Data
  • Object
show all
Extended by:
T::Sig
Includes:
DiffLine
Defined in:
lib/xberg/native.rb

Overview

Line added in the "after" version.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#valueObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



4159
4160
4161
# File 'lib/xberg/native.rb', line 4159

def value
  @value
end

Class Method Details

.from_hash(hash) ⇒ Object



4176
4177
4178
# File 'lib/xberg/native.rb', line 4176

def self.from_hash(hash)
  new(value: hash[:_0] || hash["_0"])
end

Instance Method Details

#added?Boolean

Returns:

  • (Boolean)


4170
# File 'lib/xberg/native.rb', line 4170

def added? = true

#context?Boolean

Returns:

  • (Boolean)


4168
# File 'lib/xberg/native.rb', line 4168

def context? = false

#removed?Boolean

Returns:

  • (Boolean)


4172
4173
4174
# File 'lib/xberg/native.rb', line 4172

def removed? = false
# @param hash [Hash] deserialized from the native extension
# @return [self]