Module: CobotClient

Defined in:
lib/cobot_client.rb,
lib/cobot_client/engine.rb,
lib/cobot_client/errors.rb,
lib/cobot_client/request.rb,
lib/cobot_client/version.rb,
lib/cobot_client/response.rb,
lib/cobot_client/api_client.rb,
lib/cobot_client/url_helper.rb,
lib/cobot_client/navigation_link.rb,
lib/cobot_client/navigation_link_service.rb

Defined Under Namespace

Modules: UrlHelper Classes: ApiClient, ConnectionError, Engine, Error, NavigationLink, NavigationLinkService, Request, Response, ResponseError

Constant Summary collapse

RESPONSE_CODE_TO_ERROR_CLASS =
::Net::HTTPResponse::CODE_TO_OBJ.to_h do |code, net_http_class|
  class_name = net_http_class.name.delete_prefix('Net::HTTP')

  class_object = Class.new(ResponseError)
  class_object.const_get(:HTTP_CODE, code)

  [code.to_i, const_set(class_name, class_object)]
end
VERSION =
'6.0.0'