Class: RomFactory::Attributes::Callable

Inherits:
Object
  • Object
show all
Defined in:
lib/rom_factory/attributes/callable.rb

Instance Method Summary collapse

Constructor Details

#initialize(block) ⇒ Callable

Returns a new instance of Callable.



4
5
6
# File 'lib/rom_factory/attributes/callable.rb', line 4

def initialize(block)
  @block = block
end

Instance Method Details

#callObject



8
9
10
# File 'lib/rom_factory/attributes/callable.rb', line 8

def call
  @block.call
end