Sha256: c969f97fb28873d7a3ea8251678fef6e5d96de64b6077c968e53207ae1d35d82
Contents?: true
Size: 1012 Bytes
Versions: 4
Compression:
Stored size: 1012 Bytes
Contents
module ApiClient module Errors class ApiClientError < StandardError def initialize(message = nil, request = nil, response = nil) message ||= "Status code: #{response.status}" if response super(message) @request = request @response = response end attr_reader :request, :response end class ConnectionFailed < ApiClientError; end class Config < ApiClientError; end class Unauthorized < ApiClientError; end class Forbidden < ApiClientError; end class NotFound < ApiClientError; end class Redirect < ApiClientError; end class BadRequest < ApiClientError; end class Unsupported < ApiClientError; end class Conflict < ApiClientError; end class Gone < ApiClientError; end class ServerError < ApiClientError; end class UnprocessableEntity < ApiClientError; end class PreconditionFailed < ApiClientError; end class Locked < ApiClientError; end class TooManyRequests < ApiClientError; end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
api_client-0.6.0-java | lib/api_client/errors.rb |
api_client-0.6.0 | lib/api_client/errors.rb |
api_client-0.5.26-java | lib/api_client/errors.rb |
api_client-0.5.26 | lib/api_client/errors.rb |