Exception: ZuoraAPI::Exceptions::ZuoraDataIntegrity
- Defined in:
- lib/zuora_api/exceptions.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#default_message ⇒ Object
writeonly
Sets the attribute default_message.
-
#response ⇒ Object
readonly
Returns the value of attribute response.
Instance Method Summary collapse
-
#initialize(message = nil, response = nil, *args) ⇒ ZuoraDataIntegrity
constructor
A new instance of ZuoraDataIntegrity.
- #to_s ⇒ Object
Constructor Details
#initialize(message = nil, response = nil, *args) ⇒ ZuoraDataIntegrity
Returns a new instance of ZuoraDataIntegrity.
94 95 96 97 98 99 |
# File 'lib/zuora_api/exceptions.rb', line 94 def initialize( = nil,response=nil, *args) @code = response.present? && response.class.to_s == "HTTParty::Response" ? response.code : nil @message = @response = response @default_message = "Operation failed due to lock competition. Please retry" end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
91 92 93 |
# File 'lib/zuora_api/exceptions.rb', line 91 def code @code end |
#default_message=(value) ⇒ Object (writeonly)
Sets the attribute default_message
92 93 94 |
# File 'lib/zuora_api/exceptions.rb', line 92 def (value) @default_message = value end |
#response ⇒ Object (readonly)
Returns the value of attribute response.
91 92 93 |
# File 'lib/zuora_api/exceptions.rb', line 91 def response @response end |
Instance Method Details
#to_s ⇒ Object
101 102 103 |
# File 'lib/zuora_api/exceptions.rb', line 101 def to_s @message || @default_message end |