module Sequel::Plugins::Caching::InstanceMethods
Public Instance Methods
Source
# File lib/sequel/plugins/caching.rb 162 def before_update 163 cache_delete 164 super 165 end
Remove the object from the cache when updating
Calls superclass method
Source
# File lib/sequel/plugins/caching.rb 170 def cache_key 171 model.cache_key(pk) 172 end
Return a key unique to the underlying record for caching, based on the primary key value(s) for the object. If the model does not have a primary key, raise an Error.
Source
# File lib/sequel/plugins/caching.rb 175 def delete 176 cache_delete 177 super 178 end
Remove the object from the cache when deleting
Calls superclass method
Private Instance Methods
Source
# File lib/sequel/plugins/caching.rb 183 def cache_delete 184 model.cache_delete_pk(pk) 185 end
Delete this object from the cache