Class: YamlNormalizer::Services::Base
- Inherits:
-
Object
- Object
- YamlNormalizer::Services::Base
- Defined in:
- lib/yaml_normalizer/services/base.rb
Overview
The Base Service provides a convenience class method “call” to initialize the Service with the given arguments and call the method “call” on the instance.
Class Method Summary collapse
-
.call(*args) ⇒ Object
A convenience class method to initialize Normalize with the given arguments and call the method “call” on the instance.
Instance Method Summary collapse
-
#call ⇒ Object
Inherit from Base and implement the call method.
-
#initialize(*args) ⇒ Base
constructor
Creates a service object.
Constructor Details
#initialize(*args) ⇒ Base
Creates a service object. Inherit from Base and implement this method.
34 35 36 |
# File 'lib/yaml_normalizer/services/base.rb', line 34 def initialize(*args) @args = args end |
Class Method Details
.call(*args) ⇒ Object
A convenience class method to initialize Normalize with the given arguments and call the method “call” on the instance.
41 42 43 |
# File 'lib/yaml_normalizer/services/base.rb', line 41 def self.call(*args) new(*args).call end |
Instance Method Details
#call ⇒ Object
Inherit from Base and implement the call method
47 48 49 |
# File 'lib/yaml_normalizer/services/base.rb', line 47 def call raise NotImplementedError end |