Class: Differential::Parser::Record

Inherits:
Object
  • Object
show all
Defined in:
lib/differential/parser/record.rb

Overview

Represents a parsed record object. This is ultimately what a Reader creates and is serves as input into the Calculator module.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id:, group_id:, value:, data:) ⇒ Record

Returns a new instance of Record.



17
18
19
20
21
22
# File 'lib/differential/parser/record.rb', line 17

def initialize(id:, group_id:, value:, data:)
  @id       = id
  @group_id = group_id
  @value    = value
  @data     = data
end

Instance Attribute Details

#dataObject (readonly)

Returns the value of attribute data.



15
16
17
# File 'lib/differential/parser/record.rb', line 15

def data
  @data
end

#group_idObject (readonly)

Returns the value of attribute group_id.



15
16
17
# File 'lib/differential/parser/record.rb', line 15

def group_id
  @group_id
end

#idObject (readonly)

Returns the value of attribute id.



15
16
17
# File 'lib/differential/parser/record.rb', line 15

def id
  @id
end

#valueObject (readonly)

Returns the value of attribute value.



15
16
17
# File 'lib/differential/parser/record.rb', line 15

def value
  @value
end