Exception: ZuoraAPI::Exceptions::ZuoraAPIAuthenticationTypeError

Inherits:
Error
  • Object
show all
Defined in:
lib/zuora_api/exceptions.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Error

#parse_message

Constructor Details

#initialize(message = nil, response = nil, errors = [], successes = [], *args) ⇒ ZuoraAPIAuthenticationTypeError

Returns a new instance of ZuoraAPIAuthenticationTypeError.



214
215
216
217
218
219
# File 'lib/zuora_api/exceptions.rb', line 214

def initialize(message = nil,response=nil, errors = [], successes = [], *args)
  @code = response.class.to_s == "HTTParty::Response" ? response.code : nil
  @message = parse_message(message)
  @response = response
  @default_message = "Authentication type is not supported by this Login"
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



211
212
213
# File 'lib/zuora_api/exceptions.rb', line 211

def code
  @code
end

#default_message=(value) ⇒ Object (writeonly)

Sets the attribute default_message

Parameters:

  • value

    the value to set the attribute default_message to.



212
213
214
# File 'lib/zuora_api/exceptions.rb', line 212

def default_message=(value)
  @default_message = value
end

#responseObject (readonly)

Returns the value of attribute response.



211
212
213
# File 'lib/zuora_api/exceptions.rb', line 211

def response
  @response
end

Instance Method Details

#to_sObject



221
222
223
# File 'lib/zuora_api/exceptions.rb', line 221

def to_s
  @message || @default_message
end