Class: FlowcommerceSpree::LoggingHttpHandler
- Inherits:
-
Io::Flow::V0::HttpClient::DefaultHttpHandler
- Object
- Io::Flow::V0::HttpClient::DefaultHttpHandler
- FlowcommerceSpree::LoggingHttpHandler
- Defined in:
- lib/flowcommerce_spree/logging_http_handler.rb
Instance Attribute Summary collapse
-
#http_client ⇒ Object
readonly
Returns the value of attribute http_client.
-
#logger ⇒ Object
readonly
Returns the value of attribute logger.
Instance Method Summary collapse
-
#initialize(logger: FlowcommerceSpree.logger) ⇒ LoggingHttpHandler
constructor
A new instance of LoggingHttpHandler.
- #instance(base_uri, _path) ⇒ Object
Constructor Details
#initialize(logger: FlowcommerceSpree.logger) ⇒ LoggingHttpHandler
Returns a new instance of LoggingHttpHandler.
7 8 9 |
# File 'lib/flowcommerce_spree/logging_http_handler.rb', line 7 def initialize(logger: FlowcommerceSpree.logger) @logger = logger end |
Instance Attribute Details
#http_client ⇒ Object (readonly)
Returns the value of attribute http_client.
5 6 7 |
# File 'lib/flowcommerce_spree/logging_http_handler.rb', line 5 def http_client @http_client end |
#logger ⇒ Object (readonly)
Returns the value of attribute logger.
5 6 7 |
# File 'lib/flowcommerce_spree/logging_http_handler.rb', line 5 def logger @logger end |
Instance Method Details
#instance(base_uri, _path) ⇒ Object
11 12 13 |
# File 'lib/flowcommerce_spree/logging_http_handler.rb', line 11 def instance(base_uri, _path) @http_client = LoggingHttpClient.new(base_uri, logger: @logger) end |