lib/eddy/data/persistence/memory.rb in eddy-0.8.3 vs lib/eddy/data/persistence/memory.rb in eddy-0.8.4
- old
+ new
@@ -6,29 +6,19 @@
# @return [void]
def initialize()
@data = {
interchange_control_numbers: [],
- functional_group_control_numbers: {},
transaction_set_control_numbers: {},
}
end
# @return [Array<Integer>]
def interchange_control_numbers()
return @data[:interchange_control_numbers]
end
- # @param functional_group [String]
- # @return [Array<Integer>]
- def functional_group_control_numbers(functional_group)
- unless @data[:functional_group_control_numbers].key?(functional_group)
- @data[:functional_group_control_numbers][functional_group] = []
- end
- return @data[:functional_group_control_numbers][functional_group]
- end
-
# @param transaction_set_id [String]
# @return [Array<Integer>]
def transaction_set_control_numbers(transaction_set_id)
unless @data[:transaction_set_control_numbers].key?(transaction_set_id)
@data[:transaction_set_control_numbers][transaction_set_id] = []
@@ -38,17 +28,9 @@
# @param new_ctrl_num [Integer]
# @return [void]
def add_interchange_control_number(new_ctrl_num)
self.interchange_control_numbers.append(new_ctrl_num)
- return nil
- end
-
- # @param functional_group [String]
- # @param new_ctrl_num [Integer]
- # @return [void]
- def add_functional_group_control_number(functional_group, new_ctrl_num)
- self.functional_group_control_numbers(functional_group).append(new_ctrl_num)
return nil
end
# @param transaction_set_id [String]
# @param new_ctrl_num [Integer]