diff options
author | Vijay Dev <vijaydev.cse@gmail.com> | 2013-04-11 22:58:14 +0530 |
---|---|---|
committer | Vijay Dev <vijaydev.cse@gmail.com> | 2013-04-11 22:58:14 +0530 |
commit | b15ce4a006756a0b6cacfb9593d88c9a7dfd8eb0 (patch) | |
tree | 573c2401b48841a28209e93664af131146eea31e /activerecord/lib/active_record/attribute_methods | |
parent | a24ef8611d19bce9c98aa21ee59d9dd0a08ecec5 (diff) | |
parent | 8a347d925d08a4fe648c6fe7c5e8c948e186c9bb (diff) | |
download | rails-b15ce4a006756a0b6cacfb9593d88c9a7dfd8eb0.tar.gz rails-b15ce4a006756a0b6cacfb9593d88c9a7dfd8eb0.tar.bz2 rails-b15ce4a006756a0b6cacfb9593d88c9a7dfd8eb0.zip |
Merge branch 'master' of github.com:lifo/docrails
Conflicts:
guides/source/action_mailer_basics.md
Diffstat (limited to 'activerecord/lib/active_record/attribute_methods')
-rw-r--r-- | activerecord/lib/active_record/attribute_methods/serialization.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/attribute_methods/serialization.rb b/activerecord/lib/active_record/attribute_methods/serialization.rb index 25d62fdb85..ae49fd4b88 100644 --- a/activerecord/lib/active_record/attribute_methods/serialization.rb +++ b/activerecord/lib/active_record/attribute_methods/serialization.rb @@ -11,6 +11,12 @@ module ActiveRecord end module ClassMethods + ## + # :method: serialized_attributes + # + # Returns a hash of all the attributes that have been specified for + # serialization as keys and their class restriction as values. + # If you have an attribute that needs to be saved to the database as an # object, and retrieved as the same object, then specify the name of that # attribute using this method and it will be handled automatically. The @@ -44,6 +50,7 @@ module ActiveRecord end end + # *DEPRECATED*: Use ActiveRecord::AttributeMethods::Serialization::ClassMethods#serialized_attributes class level method instead. def serialized_attributes message = "Instance level serialized_attributes method is deprecated, please use class level method." ActiveSupport::Deprecation.warn message |