Class: JsonUpdater::JsonFullBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/json_updater/json_full_builder.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json_changeable:, json_etalon:) ⇒ JsonFullBuilder

Returns a new instance of JsonFullBuilder.



11
12
13
14
# File 'lib/json_updater/json_full_builder.rb', line 11

def initialize(json_changeable:, json_etalon:)
  @json_changeable = json_changeable
  @json_etalon = json_etalon
end

Instance Attribute Details

#json_changeableObject (readonly)

Returns the value of attribute json_changeable.



5
6
7
# File 'lib/json_updater/json_full_builder.rb', line 5

def json_changeable
  @json_changeable
end

#json_etalonObject (readonly)

Returns the value of attribute json_etalon.



5
6
7
# File 'lib/json_updater/json_full_builder.rb', line 5

def json_etalon
  @json_etalon
end

Class Method Details

.build(json_changeable:, json_etalon:) ⇒ Object



7
8
9
# File 'lib/json_updater/json_full_builder.rb', line 7

def self.build(json_changeable:, json_etalon:)
  new(json_changeable: json_changeable, json_etalon: json_etalon).build
end

Instance Method Details

#buildObject



16
17
18
# File 'lib/json_updater/json_full_builder.rb', line 16

def build
  recursion_updation(json_changeable, json_etalon)
end