Class: Abroad::Serializers::Yaml::YamlSerializer
- Inherits:
-
Serializer
- Object
- Serializer
- Abroad::Serializers::Yaml::YamlSerializer
- Defined in:
- lib/abroad/serializers/yaml/yaml_serializer.rb
Direct Known Subclasses
Constant Summary
Constants inherited from Serializer
Instance Attribute Summary collapse
-
#writer ⇒ Object
readonly
Returns the value of attribute writer.
Attributes inherited from Serializer
Instance Method Summary collapse
-
#initialize(stream, locale, options = {}) ⇒ YamlSerializer
constructor
A new instance of YamlSerializer.
Methods inherited from Serializer
#close, #encoding, #flush, from_stream, open, #write_key_value, #write_raw
Constructor Details
#initialize(stream, locale, options = {}) ⇒ YamlSerializer
Returns a new instance of YamlSerializer.
11 12 13 14 |
# File 'lib/abroad/serializers/yaml/yaml_serializer.rb', line 11 def initialize(stream, locale, = {}) super @writer = YamlWriteStream.from_stream(stream, encoding) end |
Instance Attribute Details
#writer ⇒ Object (readonly)
Returns the value of attribute writer.
9 10 11 |
# File 'lib/abroad/serializers/yaml/yaml_serializer.rb', line 9 def writer @writer end |