Class: OEXRWrapper::Resource
- Inherits:
-
Object
- Object
- OEXRWrapper::Resource
- Defined in:
- lib/oexrwrapper/resource.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
Instance Method Summary collapse
- #get_request(url, params: {}) ⇒ Object
-
#initialize(client) ⇒ Resource
constructor
A new instance of Resource.
Constructor Details
#initialize(client) ⇒ Resource
Returns a new instance of Resource.
5 6 7 |
# File 'lib/oexrwrapper/resource.rb', line 5 def initialize(client) @client = client end |
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
3 4 5 |
# File 'lib/oexrwrapper/resource.rb', line 3 def client @client end |
Instance Method Details
#get_request(url, params: {}) ⇒ Object
9 10 11 |
# File 'lib/oexrwrapper/resource.rb', line 9 def get_request(url, params: {}) raise_response client.connection.get("#{url}.json", params) end |