Class: Edi::NullProcessor
- Inherits:
-
BaseService
- Object
- BaseService
- Edi::NullProcessor
- Defined in:
- app/services/edi/null_processor.rb
Instance Attribute Summary collapse
-
#orchestrator ⇒ Object
readonly
Returns the value of attribute orchestrator.
-
#processor_type ⇒ Object
readonly
Returns the value of attribute processor_type.
Instance Method Summary collapse
-
#initialize(orchestrator, processor_type, options = {}) ⇒ NullProcessor
constructor
A new instance of NullProcessor.
- #method_missing(_meth, *_args) ⇒ Object
-
#process(*args) ⇒ Object
Retrieves messages according to the partner config.
Methods inherited from BaseService
#log_debug, #log_error, #log_info, #log_warning, #logger, #options, #tagged_logger
Constructor Details
#initialize(orchestrator, processor_type, options = {}) ⇒ NullProcessor
Returns a new instance of NullProcessor.
7 8 9 10 11 |
# File 'app/services/edi/null_processor.rb', line 7 def initialize(orchestrator, processor_type, = {}) @orchestrator = orchestrator @processor_type = processor_type super() end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(_meth, *_args) ⇒ Object
19 20 21 22 |
# File 'app/services/edi/null_processor.rb', line 19 def method_missing(_meth, *_args) # Do nothing logger.info "Processor #{processor_type} not defined for #{orchestrator.partner}" end |
Instance Attribute Details
#orchestrator ⇒ Object (readonly)
Returns the value of attribute orchestrator.
5 6 7 |
# File 'app/services/edi/null_processor.rb', line 5 def orchestrator @orchestrator end |
#processor_type ⇒ Object (readonly)
Returns the value of attribute processor_type.
5 6 7 |
# File 'app/services/edi/null_processor.rb', line 5 def processor_type @processor_type end |
Instance Method Details
#process(*args) ⇒ Object
Retrieves messages according to the partner config
14 15 16 17 |
# File 'app/services/edi/null_processor.rb', line 14 def process(*args) # Do nothing logger.debug("Processor not defined", processor_type: processor_type, partner: orchestrator.partner) end |