Module: Linzer::Message::Adapter::HTTPGem::Common
Overview
Shared functionality for http.rb request and response adapters.
Instance Method Summary collapse
-
#attach!(signature) ⇒ Object
Attaches a signature to the response.
-
#header(name) ⇒ String?
Retrieves a header value by name.
Instance Method Details
#attach!(signature) ⇒ Object
Attaches a signature to the response.
26 27 28 29 |
# File 'lib/linzer/message/adapter/http_gem/common.rb', line 26 def attach!(signature) signature.to_h.each { |h, v| @operation.headers[h] = v } @operation end |
#header(name) ⇒ String?
Retrieves a header value by name.
19 20 21 |
# File 'lib/linzer/message/adapter/http_gem/common.rb', line 19 def header(name) @operation.headers[name] end |