module Sequel::Plugins::IdentityMap::InstanceMethods

Public Instance Methods

delete() click to toggle source

Remove instances from the identity map cache if they are deleted.

# File lib/sequel/plugins/identity_map.rb, line 205
def delete
  super
  if idm = model.identity_map
    idm.delete(model.identity_map_key(pk))
  end
  self
end
merge_db_update(row) click to toggle source

Merge the current values into the values provided in the row, ensuring that current values are not overridden by new values.

# File lib/sequel/plugins/identity_map.rb, line 215
def merge_db_update(row)
  @values = row.merge(@values)
end