Module: Persistence::Object::Flat::ObjectInstance

Included in:
Persistence::Object::Flat
Defined in:
lib/persistence/object/flat/object_instance.rb

Overview

Instance methods for flat objects enabled with persistence capabilities.

Instance Method Summary collapse

Instance Method Details

#persistence_hash_to_portHash

Generate hash representing object.

Returns:

  • (Hash)

    Hash representing information to reproduce object instance.



18
19
20
21
22
# File 'lib/persistence/object/flat/object_instance.rb', line 18

def persistence_hash_to_port

  return { persistence_bucket.primary_key_for_attribute_name( self, self.class.to_s ) => self }

end