Class: NxtHttpClient::Config

Inherits:
Struct
  • Object
show all
Defined in:
lib/nxt_http_client/config.rb

Instance Method Summary collapse

Constructor Details

#initialize(request_options: ActiveSupport::HashWithIndifferentAccess.new, base_url: '', x_request_id_proc: nil) ⇒ Config

Returns a new instance of Config.



5
6
7
8
9
# File 'lib/nxt_http_client/config.rb', line 5

def initialize(request_options: ActiveSupport::HashWithIndifferentAccess.new, base_url: '', x_request_id_proc: nil)
  self.request_options = request_options
  self.base_url = base_url
  self.x_request_id_proc = x_request_id_proc
end

Instance Method Details

#dupObject



11
12
13
# File 'lib/nxt_http_client/config.rb', line 11

def dup
  self.class.new(**to_h.deep_dup)
end