Class: Datadog::Transport::HTTP::API::Endpoint
- Inherits:
-
Object
- Object
- Datadog::Transport::HTTP::API::Endpoint
- Defined in:
- lib/ddtrace/transport/http/api/endpoint.rb
Overview
Endpoint
Direct Known Subclasses
Instance Attribute Summary collapse
-
#path ⇒ Object
readonly
Returns the value of attribute path.
-
#verb ⇒ Object
readonly
Returns the value of attribute verb.
Instance Method Summary collapse
- #call(env) {|env| ... } ⇒ Object
-
#initialize(verb, path) ⇒ Endpoint
constructor
A new instance of Endpoint.
Constructor Details
#initialize(verb, path) ⇒ Endpoint
Returns a new instance of Endpoint.
13 14 15 16 |
# File 'lib/ddtrace/transport/http/api/endpoint.rb', line 13 def initialize(verb, path) @verb = verb @path = path end |
Instance Attribute Details
#path ⇒ Object (readonly)
Returns the value of attribute path.
9 10 11 |
# File 'lib/ddtrace/transport/http/api/endpoint.rb', line 9 def path @path end |
#verb ⇒ Object (readonly)
Returns the value of attribute verb.
9 10 11 |
# File 'lib/ddtrace/transport/http/api/endpoint.rb', line 9 def verb @verb end |
Instance Method Details
#call(env) {|env| ... } ⇒ Object
18 19 20 21 22 |
# File 'lib/ddtrace/transport/http/api/endpoint.rb', line 18 def call(env) env.verb = verb env.path = path yield(env) end |