aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/type/binary.rb
Commit message (Collapse)AuthorAgeFilesLines
* Rm `Type#type_cast`Sean Griffin2015-02-171-1/+1
| | | | | | | | | This helper no longer makes sense as a separate method. Instead I'll just have `deserialize` call `cast` by default. This led to a random infinite loop in the `JSON` pg type, when it called `super` from `deserialize`. Not really a great way to fix that other than not calling super, or continuing to have the separate method, which makes the public API differ from what we say it is.
* `type_cast_for_database` -> `serialize`Sean Griffin2015-02-171-1/+1
|
* `Type#type_cast_from_database` -> `Type#deserialize`Sean Griffin2015-02-171-1/+1
|
* Correctly detect mutation on serialized columns mapping to binarySean Griffin2014-08-271-0/+10
| | | | Fixes #16701
* active_record: Type cast booleans and durations for string columns.Dylan Thacker-Smith2014-07-061-1/+1
|
* add missing `:nodoc:` for recent refactorings. [ci skip]Yves Senn2014-06-241-1/+1
| | | | | | | | | | Adding `# :nodoc:` to the parent `class` / `module` is not going to ignore nested classes or modules. There is a modifier `# :nodoc: all` but sadly the containing class or module will continue to be in the docs. /cc @sgrif
* Make `_before_type_cast` actually be before type castSean Griffin2014-06-091-0/+9
| | | | | | | | | | | | | - The following is now true for all types, all the time - `model.attribute_before_type_cast == given_value` - `model.attribute == model.save_and_reload.attribute` - `model.attribute == model.dup.attribute` - `model.attribute == YAML.load(YAML.dump(model)).attribute` - Removes the remaining types implementing `type_cast_for_write` - Simplifies the implementation of time zone aware attributes - Brings tz aware attributes closer to being implemented as an attribute decorator - Adds additional point of control for custom types
* Removed unused `klass` definitions from typesSean Griffin2014-06-061-4/+0
| | | | Only `Date` and `Time` are handled.
* Refactor quoting of binary data to not be based on the column typeSean Griffin2014-06-031-0/+18
|
* Move types to the top level `ActiveRecord` namespaceSean Griffin2014-05-271-0/+17
`ActiveRecord::ConnectionAdapters::Type::Value` => `ActiveRecord::Type::Value`