Class: RequestConfig
- Inherits:
-
Object
- Object
- RequestConfig
- Defined in:
- lib/calimero/types/rpc.rb
Instance Attribute Summary collapse
-
#headers ⇒ Object
Returns the value of attribute headers.
-
#timeout ⇒ Object
Returns the value of attribute timeout.
Instance Method Summary collapse
-
#initialize(timeout: nil, headers: nil) ⇒ RequestConfig
constructor
A new instance of RequestConfig.
- #to_h ⇒ Object
Constructor Details
#initialize(timeout: nil, headers: nil) ⇒ RequestConfig
Returns a new instance of RequestConfig.
47 48 49 50 |
# File 'lib/calimero/types/rpc.rb', line 47 def initialize(timeout: nil, headers: nil) @timeout = timeout @headers = headers end |
Instance Attribute Details
#headers ⇒ Object
Returns the value of attribute headers.
45 46 47 |
# File 'lib/calimero/types/rpc.rb', line 45 def headers @headers end |
#timeout ⇒ Object
Returns the value of attribute timeout.
45 46 47 |
# File 'lib/calimero/types/rpc.rb', line 45 def timeout @timeout end |
Instance Method Details
#to_h ⇒ Object
52 53 54 55 56 57 |
# File 'lib/calimero/types/rpc.rb', line 52 def to_h { timeout: @timeout, headers: @headers } end |