Class: SearchFlip::HTTPClient

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/search_flip/http_client.rb

Overview

The SearchFlip::HTTPClient class wraps the http gem, is for internal use and responsible for the http request/response handling, ie communicating with Elasticsearch.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(plugins: []) ⇒ HTTPClient

Returns a new instance of HTTPClient.



9
10
11
12
# File 'lib/search_flip/http_client.rb', line 9

def initialize(plugins: [])
  self.request = HTTP
  self.plugins = plugins
end

Instance Attribute Details

#pluginsObject

Returns the value of attribute plugins.



7
8
9
# File 'lib/search_flip/http_client.rb', line 7

def plugins
  @plugins
end

#requestObject

Returns the value of attribute request.



7
8
9
# File 'lib/search_flip/http_client.rb', line 7

def request
  @request
end