class ROM::Memory::Commands::Create

In-memory create command

@api public

Public Instance Methods

execute(tuples) click to toggle source

@see ROM::Commands::Create#execute

# File lib/rom/memory/commands.rb, line 19
def execute(tuples)
  Array([tuples]).flatten.map { |tuple|
    attributes = input[tuple]
    relation.insert(attributes.to_h)
    attributes
  }.to_a
end