Module: Kibosh::Exceptions::Terminal
- Included in:
- BadRequest, HostUnknown, ImproperAddressing, InternalServerError, ItemNotFound, PolicyViolation, RemoteConnectionFailed, RemoteStreamError, UndefinedCondition
- Defined in:
- lib/kibosh/exceptions.rb
Class Method Summary collapse
Class Method Details
.included(other) ⇒ Object
26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/kibosh/exceptions.rb', line 26 def self.included other (class << other; self; end).send :define_method, :extended do |object| body = response = nil if Kibosh::Response === object response = object body = response.body else body = object end body["type"] = "terminate" body["condition"] = condition response and response.status ||= respond_to?(:status) ? status : nil end end |