Module: Sequel::Plugins::UpdatePrimaryKey::InstanceMethods
- Defined in:
- lib/sequel/plugins/update_primary_key.rb
Instance Method Summary collapse
-
#after_update ⇒ Object
Clear the pk_hash and object dataset cache, and recache the pk_hash.
-
#pk_hash ⇒ Object
Cache the pk_hash instead of generating it every time.
Instance Method Details
#after_update ⇒ Object
Clear the pk_hash and object dataset cache, and recache the pk_hash
35 36 37 38 39 |
# File 'lib/sequel/plugins/update_primary_key.rb', line 35 def after_update super @pk_hash = nil pk_hash end |
#pk_hash ⇒ Object
Cache the pk_hash instead of generating it every time
42 43 44 |
# File 'lib/sequel/plugins/update_primary_key.rb', line 42 def pk_hash @pk_hash ||= super end |