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, errors = [], successes = [], *args) ⇒ ZuoraDataIntegrity
constructor
A new instance of ZuoraDataIntegrity.
- #to_s ⇒ Object
Methods inherited from Error
Constructor Details
#initialize(message = nil, response = nil, errors = [], successes = [], *args) ⇒ ZuoraDataIntegrity
Returns a new instance of ZuoraDataIntegrity.
165 166 167 168 169 170 |
# File 'lib/zuora_api/exceptions.rb', line 165 def initialize( = nil,response=nil, errors = [], successes = [], *args) @code = 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.
162 163 164 |
# File 'lib/zuora_api/exceptions.rb', line 162 def code @code end |
#default_message=(value) ⇒ Object (writeonly)
Sets the attribute default_message
163 164 165 |
# File 'lib/zuora_api/exceptions.rb', line 163 def (value) @default_message = value end |
#response ⇒ Object (readonly)
Returns the value of attribute response.
162 163 164 |
# File 'lib/zuora_api/exceptions.rb', line 162 def response @response end |
Instance Method Details
#to_s ⇒ Object
172 173 174 |
# File 'lib/zuora_api/exceptions.rb', line 172 def to_s @message || @default_message end |