Module: TTY::Config::Marshaller
- Included in:
- TTY::Config::Marshallers::HCLMarshaller, TTY::Config::Marshallers::INIMarshaller, TTY::Config::Marshallers::JSONMarshaller, TTY::Config::Marshallers::JavaPropsMarshaller, TTY::Config::Marshallers::TOMLMarshaller, TTY::Config::Marshallers::XMLMarshaller, TTY::Config::Marshallers::YAMLMarshaller
- Defined in:
- lib/tty/config/marshaller.rb
Defined Under Namespace
Modules: ExtensionsStore
Class Method Summary collapse
- .included(base) ⇒ Object private
Instance Method Summary collapse
-
#marshal(_object, _options = {}) ⇒ Object
Marshal object into a given format.
-
#unmarshal(_content, _options = {}) ⇒ Object
Unmarshal content into a hash object.
Class Method Details
.included(base) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
9 10 11 12 13 14 15 |
# File 'lib/tty/config/marshaller.rb', line 9 def self.included(base) super # Help marshallers to declare their gem dependency base.extend DependencyLoader # Help marshallers to declare their extension matching base.extend ExtensionsStore end |
Instance Method Details
#marshal(_object, _options = {}) ⇒ Object
Marshal object into a given format
52 53 54 |
# File 'lib/tty/config/marshaller.rb', line 52 def marshal(_object, = {}) raise NotImplementedError end |
#unmarshal(_content, _options = {}) ⇒ Object
Unmarshal content into a hash object
61 62 63 |
# File 'lib/tty/config/marshaller.rb', line 61 def unmarshal(_content, = {}) raise NotImplementedError end |