Exception: Proxy::OpenSCAP::OpenSCAPException
- Inherits:
-
Exception
- Object
- Exception
- Proxy::OpenSCAP::OpenSCAPException
- Defined in:
- lib/smart_proxy_openscap/openscap_exception.rb
Instance Attribute Summary collapse
-
#message ⇒ Object
Returns the value of attribute message.
-
#response ⇒ Object
Returns the value of attribute response.
Instance Method Summary collapse
- #http_body ⇒ Object
- #http_code ⇒ Object
-
#initialize(response = nil) ⇒ OpenSCAPException
constructor
A new instance of OpenSCAPException.
Constructor Details
#initialize(response = nil) ⇒ OpenSCAPException
Returns a new instance of OpenSCAPException.
5 6 7 8 |
# File 'lib/smart_proxy_openscap/openscap_exception.rb', line 5 def initialize(response = nil) @response = response = response. if response end |
Instance Attribute Details
#message ⇒ Object
Returns the value of attribute message.
4 5 6 |
# File 'lib/smart_proxy_openscap/openscap_exception.rb', line 4 def end |
#response ⇒ Object
Returns the value of attribute response.
3 4 5 |
# File 'lib/smart_proxy_openscap/openscap_exception.rb', line 3 def response @response end |
Instance Method Details
#http_body ⇒ Object
14 15 16 |
# File 'lib/smart_proxy_openscap/openscap_exception.rb', line 14 def http_body @response.body if @response end |
#http_code ⇒ Object
10 11 12 |
# File 'lib/smart_proxy_openscap/openscap_exception.rb', line 10 def http_code @response.code || 500 end |