Class: Xberg::DiffLineContext

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

Overview

Unchanged context line.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#valueObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



3879
3880
3881
# File 'lib/xberg/native.rb', line 3879

def value
  @value
end

Class Method Details

.from_hash(hash) ⇒ Object



3896
3897
3898
# File 'lib/xberg/native.rb', line 3896

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

Instance Method Details

#added?Boolean

Returns:

  • (Boolean)


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

def added? = false

#context?Boolean

Returns:

  • (Boolean)


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

def context? = true

#removed?Boolean

Returns:

  • (Boolean)


3892
3893
3894
# File 'lib/xberg/native.rb', line 3892

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