Class: Batches::ErrorCode6

Inherits:
Object
  • Object
show all
Defined in:
lib/batches/models/error_code6.rb

Overview

This is an error indicating there was a timeout issue to another system.

Constant Summary collapse

ERROR_CODE6 =
[
  # TODO: Write general description for TIMEOUT_DOWNSTREAM
  TIMEOUT_DOWNSTREAM = 'TIMEOUT_DOWNSTREAM'.freeze
].freeze

Class Method Summary collapse

Class Method Details

.from_value(value, default_value = TIMEOUT_DOWNSTREAM) ⇒ Object



20
21
22
23
24
# File 'lib/batches/models/error_code6.rb', line 20

def self.from_value(value, default_value = TIMEOUT_DOWNSTREAM)
  return default_value if value.nil?

  default_value
end

.validate(value) ⇒ Object



14
15
16
17
18
# File 'lib/batches/models/error_code6.rb', line 14

def self.validate(value)
  return false if value.nil?

  ERROR_CODE6.include?(value)
end