Class: Frodo::Middleware
- Inherits:
-
Faraday::Middleware
- Object
- Faraday::Middleware
- Frodo::Middleware
- Defined in:
- lib/frodo/middleware.rb
Overview
Base class that all middleware can extend. Provides some convenient helper functions.
Direct Known Subclasses
Authentication, Authorization, CustomHeaders, Gzip, InstanceURL, OdataHeaders
Defined Under Namespace
Classes: Authentication, Authorization, Caching, CustomHeaders, Gzip, InstanceURL, Logger, Multipart, OdataHeaders, RaiseError
Instance Method Summary collapse
-
#client ⇒ Object
Internal: Proxy to the client.
-
#connection ⇒ Object
Internal: Proxy to the client’s faraday connection.
-
#initialize(app, client, options) ⇒ Middleware
constructor
A new instance of Middleware.
Constructor Details
#initialize(app, client, options) ⇒ Middleware
17 18 19 20 21 |
# File 'lib/frodo/middleware.rb', line 17 def initialize(app, client, ) @app = app @client = client @options = end |
Instance Method Details
#client ⇒ Object
Internal: Proxy to the client.
24 25 26 |
# File 'lib/frodo/middleware.rb', line 24 def client @client end |
#connection ⇒ Object
Internal: Proxy to the client’s faraday connection.
29 30 31 |
# File 'lib/frodo/middleware.rb', line 29 def connection client.send(:connection) end |