Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Deprecate ActiveSupport::JSON::Variable | Erich Menge | 2012-05-30 | 1 | -1/+9 |
| | |||||
* | True, False, and Nil should be represented in as_json as themselves. | Erich Menge | 2012-05-30 | 1 | -6/+6 |
| | | | | | | | Conflicts: activesupport/lib/active_support/json/encoding.rb activesupport/test/json/encoding_test.rb | ||||
* | Use `Object#respond_to?` to determine which MultiJson API to use | Erik Michaels-Ober | 2012-04-18 | 1 | -3/+17 |
| | |||||
* | fixes in api docs | Vijay Dev | 2012-01-13 | 1 | -3/+3 |
| | |||||
* | Revert "Implement ArraySerializer and move old serialization API to a new ↵ | José Valim | 2011-11-30 | 1 | -1/+1 |
| | | | | | | | | | | | | | namespace." This reverts commit 8896b4fdc8a543157cdf4dfc378607ebf6c10ab0. Conflicts: activemodel/lib/active_model.rb activemodel/lib/active_model/serializable.rb activemodel/lib/active_model/serializer.rb activemodel/test/cases/serializer_test.rb | ||||
* | Implement ArraySerializer and move old serialization API to a new namespace. | José Valim | 2011-11-23 | 1 | -4/+4 |
| | | | | | | | | | | | | | The following constants were renamed: ActiveModel::Serialization => ActiveModel::Serializable ActiveModel::Serializers::JSON => ActiveModel::Serializable::JSON ActiveModel::Serializers::Xml => ActiveModel::Serializable::XML The main motivation for such a change is that `ActiveModel::Serializers::JSON` was not actually a serializer, but a module that when included allows the target to be serializable to JSON. With such changes, we were able to clean up the namespace to add true serializers as the ArraySerializer. | ||||
* | Set the default options value for as_json in the encoder object. | José Valim | 2011-09-30 | 1 | -2/+2 |
| | |||||
* | Removed deprecated methods and related tests from ActiveSupport | Josh Kalderimis | 2011-05-25 | 1 | -3/+0 |
| | |||||
* | Use set data structure to speed up circular reference checks on large/deeply ↵ | Andy Lindeman | 2011-05-23 | 1 | -4/+4 |
| | | | | nested objects | ||||
* | add missing require for ordered_hash dependency | Corin Langosch | 2011-05-11 | 1 | -0/+1 |
| | |||||
* | Merge pull request #248 from bigfix/enumerable_as_json | José Valim | 2011-05-07 | 1 | -1/+3 |
|\ | | | | | Enumerable should pass encoding options to children in #as_json/#to_json | ||||
| * | Enumerable should pass encoding options to children in #as_json/#to_json. | John Firebaugh | 2011-04-01 | 1 | -1/+3 |
| | | |||||
* | | AS Json parse_error makes a return for backwards compatibility, although it ↵ | Josh Kalderimis | 2011-04-19 | 1 | -0/+4 |
| | | | | | | | | will return MultiJson::DecodeError | ||||
* | | removed AS backends and instead rely on MultiJson for json decoding | Josh Kalderimis | 2011-04-18 | 4 | -227/+33 |
|/ | |||||
* | parse dates to yaml in json arrays | Diego Carrion | 2011-03-22 | 1 | -2/+2 |
| | | | | Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | test json decoding with time parsing disabled with all backends and respect ↵ | Diego Carrion | 2011-03-22 | 1 | -3/+5 |
| | | | | | | ActiveSupport.parse_json_times when converting to yaml Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | Updated the json date regex to recognize xmlschema formatted date times ↵ | Josh Kalderimis | 2011-02-12 | 1 | -1/+1 |
| | | | | | | during json decoding. [#3031 state:resolved] Signed-off-by: Santiago Pastorino and Emilio Tagua <santiago+emilioe@wyeworks.com> | ||||
* | Fixes an issue when decoding a json string which looks like a date but is ↵ | Josh Kalderimis | 2011-02-11 | 3 | -3/+21 |
| | | | | | | invalid. This DateTime parse error is now caught and the original string is instead passed back [#6286 state:resolved] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | Fix JSON decoding of newline character with Yaml backend [#3479 state:resolved] | Maxime RETY | 2011-02-02 | 1 | -2/+6 |
| | | | | Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | use ! " " YAML string literal syntax rather than removing both quotes | Aaron Patterson | 2011-01-21 | 1 | -4/+4 |
| | |||||
* | Complex struct encoding fix | Alexey Nayden | 2011-01-15 | 1 | -0/+6 |
| | | | | | | [#6077 state:committed] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | add Psych::SyntaxError to the list of rescued YAML exceptions | Aaron Patterson | 2011-01-04 | 1 | -1/+8 |
| | |||||
* | Perf: speed up json encoding. | Emilio Tagua | 2010-09-22 | 1 | -3/+2 |
| | | | | Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | fixed some issues with JSON encoding | Jakub Suder | 2010-09-07 | 1 | -6/+44 |
| | | | | | | | | | | | - as_json in ActiveModel should return a hash and handle :only/:except/:methods options - Array and Hash should call as_json on their elements - json methods should not modify options argument [#5374 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> | ||||
* | Removes unused vars | Santiago Pastorino | 2010-07-24 | 1 | -1/+1 |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | Move Date#xmlschema to conversions and add a missing require | Santiago Pastorino | 2010-07-04 | 1 | -0/+2 |
| | |||||
* | Time#formatted_offset is defined in core_ext/time/conversions | Santiago Pastorino | 2010-07-02 | 1 | -0/+1 |
| | | | | [#4979] | ||||
* | Time#as_json: use Time#formatted_offset instead of strftime %z directive, ↵ | Geoff Buesing | 2010-07-02 | 1 | -1/+1 |
| | | | | | | | | which is non-standard and inaccurate on some platforms (e.g., Mac OS X). [#4979] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> | ||||
* | Time has it own implementation of xmlschema, now AMo doesn't depend on TZInfo | Santiago Pastorino | 2010-07-02 | 1 | -2/+2 |
| | | | | | | [#4979 state:committed] Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | AS json refactor, move to_json implementation to core_ext and a cleanup a ↵ | Santiago Pastorino | 2010-07-01 | 2 | -35/+8 |
| | | | | bit the code | ||||
* | Work around the fact the JSON gem was overwriting to_json implementation for ↵ | José Valim | 2010-06-26 | 1 | -5/+14 |
| | | | | | | | all Ruby core classes. This is required because the JSON gem is incompatible with Rails behavior and was not allowing ActiveModel::Errors to be serialized. So we need to ensure Rails implementation is the one triggered. [#4890 state:resolved] | ||||
* | Fix Yajl backend discovery in ActiveSupport::JSON | Maxime RETY | 2010-06-18 | 1 | -1/+1 |
| | | | | | | [#4897 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> | ||||
* | removes spurious .rb in require | Santiago Pastorino | 2010-06-13 | 1 | -1/+1 |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | adds a comment explaining why BigDecimal#as_json returns a JSON string | Xavier Noria | 2010-05-03 | 1 | -1/+9 |
| | |||||
* | Missing require added make pass activesupport/test/json/encoding_test.rb in ↵ | Santiago Pastorino | 2010-05-02 | 1 | -0/+1 |
| | | | | | | isolation Signed-off-by: Xavier Noria <fxn@hashref.com> | ||||
* | use ordinary syntax for options to be well-formed in 1.8 | Xavier Noria | 2010-04-27 | 1 | -1/+1 |
| | |||||
* | JSON: encode objects that don't have a native JSON representation using ↵ | Jeremy Kemper | 2010-04-26 | 1 | -5/+19 |
| | | | | to_hash, if available, instead of instance_values (the old fallback) or to_s (other encoders' default). Encode BigDecimal and Regexp encode as strings to conform with other encoders. Try to transcode non-UTF-8 strings. | ||||
* | Disprefer JSONGem decoder since it only decodes JSON objects | Jeremy Kemper | 2010-03-09 | 1 | -1/+1 |
| | |||||
* | Automatically prefer Yajl or JSON backend over Yaml, if available | Jeremy Kemper | 2010-02-05 | 1 | -1/+16 |
| | |||||
* | Add yajl-ruby as a JSON parsing backend | Brian Lopez | 2010-02-05 | 1 | -0/+40 |
| | | | | | | [#2666 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> | ||||
* | Changed the default ActiveSupport.use_standard_json_time_format from false ↵ | David Heinemeier Hansson | 2010-01-03 | 1 | -1/+2 |
| | | | | | | to true and ActiveSupport.escape_html_entities_in_json from true to false to match previously announced Rails 3 defaults [DHH] | ||||
* | Fix ActiveSupport::JSON encoding of control characters [\x00-\x1f] | Dwayne Litzenberger | 2009-12-23 | 1 | -2/+11 |
| | | | | | | | | | | | | | | According to RFC 4627, only the following Unicode code points are allowed unescaped in JSON: unescaped = %x20-21 / %x23-5B / %x5D-10FFFF However, ActiveSupport::JSON did not escape the range %x00-1f. This caused parse errors when trying to decode the resulting output. [#3345 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> | ||||
* | Repair time dependencies | Jeremy Kemper | 2009-11-14 | 1 | -1/+1 |
| | |||||
* | Ruby 1.9.2: work around changes to flatten and nil.to_str | Jeremy Kemper | 2009-11-08 | 1 | -9/+12 |
| | |||||
* | Clarify date/time dependencies | Jeremy Kemper | 2009-11-02 | 1 | -3/+0 |
| | |||||
* | Clean up spurious JSON decoding test failure | Jeremy Kemper | 2009-09-13 | 3 | -8/+5 |
| | |||||
* | Fix that JSON parser fails to read escaped backslashes. | Daniel Sheppard | 2009-08-09 | 1 | -1/+4 |
| | | | | | | [#973 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> | ||||
* | Fixed a bug in JSON decoding with Yaml backend, where a combination of ↵ | Bas Van Klinkenberg | 2009-08-08 | 1 | -7/+10 |
| | | | | | | dates, escaped or unicode encoded data and arrays would make the parser fail with a ParseError exception. [#2831 state:resolved] Signed-off-by: Yehuda Katz <wycats@gmail.com> | ||||
* | JSON.escape returns UTF-8 strings | Jeremy Kemper | 2009-07-01 | 1 | -5/+7 |
| | | | | [#2849 state:resolved] | ||||
* | uses Hash#except/slice | Jeremy Kemper | 2009-07-01 | 1 | -0/+2 |
| |