Exception: KubeException
- Inherits:
-
StandardError
- Object
- StandardError
- KubeException
- Defined in:
- lib/kubeclient/kube_exception.rb
Overview
Kubernetes HTTP Exceptions
Instance Attribute Summary collapse
-
#error_code ⇒ Object
readonly
Returns the value of attribute error_code.
-
#message ⇒ Object
readonly
Returns the value of attribute message.
-
#response ⇒ Object
readonly
Returns the value of attribute response.
Instance Method Summary collapse
-
#initialize(error_code, message, response) ⇒ KubeException
constructor
A new instance of KubeException.
- #to_s ⇒ Object
Constructor Details
#initialize(error_code, message, response) ⇒ KubeException
Returns a new instance of KubeException.
5 6 7 8 9 |
# File 'lib/kubeclient/kube_exception.rb', line 5 def initialize(error_code, , response) @error_code = error_code @message = @response = response end |
Instance Attribute Details
#error_code ⇒ Object (readonly)
Returns the value of attribute error_code.
3 4 5 |
# File 'lib/kubeclient/kube_exception.rb', line 3 def error_code @error_code end |
#message ⇒ Object (readonly)
Returns the value of attribute message.
3 4 5 |
# File 'lib/kubeclient/kube_exception.rb', line 3 def @message end |
#response ⇒ Object (readonly)
Returns the value of attribute response.
3 4 5 |
# File 'lib/kubeclient/kube_exception.rb', line 3 def response @response end |
Instance Method Details
#to_s ⇒ Object
11 12 13 |
# File 'lib/kubeclient/kube_exception.rb', line 11 def to_s 'HTTP status code ' + @error_code.to_s + ', ' + @message end |