Exception: Puppet::Network::HTTP::Error::HTTPError
- Defined in:
- lib/puppet/network/http/error.rb
Direct Known Subclasses
HTTPBadRequestError, HTTPMethodNotAllowedError, HTTPNotAcceptableError, HTTPNotAuthorizedError, HTTPNotFoundError, HTTPServerError, HTTPUnsupportedMediaTypeError
Instance Attribute Summary collapse
-
#issue_kind ⇒ Object
readonly
Returns the value of attribute issue_kind.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(message, status, issue_kind) ⇒ HTTPError
constructor
A new instance of HTTPError.
- #to_json ⇒ Object
Constructor Details
#initialize(message, status, issue_kind) ⇒ HTTPError
Returns a new instance of HTTPError.
9 10 11 12 13 |
# File 'lib/puppet/network/http/error.rb', line 9 def initialize(, status, issue_kind) super() @status = status @issue_kind = issue_kind end |
Instance Attribute Details
#issue_kind ⇒ Object (readonly)
Returns the value of attribute issue_kind.
7 8 9 |
# File 'lib/puppet/network/http/error.rb', line 7 def issue_kind @issue_kind end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
7 8 9 |
# File 'lib/puppet/network/http/error.rb', line 7 def status @status end |
Instance Method Details
#to_json ⇒ Object
15 16 17 |
# File 'lib/puppet/network/http/error.rb', line 15 def to_json JSON({:message => , :issue_kind => @issue_kind}) end |