Class: Ougai::Serializers::JsonOj
- Inherits:
-
Ougai::Serializer
- Object
- Ougai::Serializer
- Ougai::Serializers::JsonOj
- Defined in:
- lib/ougai/serializers/json_oj.rb
Constant Summary collapse
- OJ_OPTIONS =
{ mode: :custom, time_format: :xmlschema, use_as_json: true, use_to_hash: true, use_to_json: true }
Instance Method Summary collapse
Methods inherited from Ougai::Serializer
Instance Method Details
#serialize(data) ⇒ Object
10 11 12 |
# File 'lib/ougai/serializers/json_oj.rb', line 10 def serialize(data) Oj.dump(data, OJ_OPTIONS) end |