Module: ROM::Memoizable::ClassInterface Private

Defined in:
lib/rom/support/memoizable.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Instance Method Summary collapse

Instance Method Details

#memoize(*names) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



10
11
12
# File 'lib/rom/support/memoizable.rb', line 10

def memoize(*names)
  prepend(Memoizer.new(self, names))
end

#newObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



14
15
16
17
18
# File 'lib/rom/support/memoizable.rb', line 14

def new(*)
  obj = super
  obj.instance_variable_set(:@__memoized__, MEMOIZED_HASH.dup)
  obj
end