Class: ActsAsTable::Mapper::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/acts_as_table/mapper.rb

Overview

ActsAsTable mapper object (abstract).

Instance Method Summary collapse

Constructor Details

#initialize {|base| ... } ⇒ ActsAsTable::Mapper::Base

Returns a new ActsAsTable mapper object.

Yield Parameters:

Yield Returns:

  • (void)


11
12
13
14
15
16
17
18
# File 'lib/acts_as_table/mapper.rb', line 11

def initialize(&block)
  if block_given?
    case block.arity
      when 1 then block.call(self)
      else self.instance_eval(&block)
    end
  end
end