Class: TwitterFriendly::Serializer::OjCoder
- Inherits:
-
Coder
- Object
- Coder
- TwitterFriendly::Serializer::OjCoder
show all
- Defined in:
- lib/twitter_friendly/serializer.rb
Instance Method Summary
collapse
Methods inherited from Coder
#initialize, instance
Instance Method Details
#decode(str) ⇒ Object
74
75
76
|
# File 'lib/twitter_friendly/serializer.rb', line 74
def decode(str)
@coder.load(str, symbol_keys: true, mode: :compat)
end
|
#encode(obj) ⇒ Object
70
71
72
|
# File 'lib/twitter_friendly/serializer.rb', line 70
def encode(obj)
@coder.dump(obj, mode: :compat)
end
|