Exception: AzureSTT::ServiceError

Inherits:
Error
  • Object
show all
Defined in:
lib/azure_stt/errors.rb

Overview

Error raised when there is an error 400

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(code:, message:, azure_message:) ⇒ ServiceError

Returns a new instance of ServiceError.



15
16
17
18
# File 'lib/azure_stt/errors.rb', line 15

def initialize(code:, message:, azure_message:)
  @code = code
  super("#{message} (#{code}): #{azure_message}")
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



13
14
15
# File 'lib/azure_stt/errors.rb', line 13

def code
  @code
end