Class: Bstat2google::ApiClient
- Inherits:
-
Object
- Object
- Bstat2google::ApiClient
- Defined in:
- lib/bstat2google.rb
Instance Attribute Summary collapse
-
#auth_token ⇒ Object
Returns the value of attribute auth_token.
-
#end_point ⇒ Object
Returns the value of attribute end_point.
-
#rest_client ⇒ Object
Returns the value of attribute rest_client.
Instance Method Summary collapse
- #get(url, options = {}) ⇒ Object
-
#initialize(attrs = {}) ⇒ ApiClient
constructor
A new instance of ApiClient.
Constructor Details
#initialize(attrs = {}) ⇒ ApiClient
Returns a new instance of ApiClient.
29 30 31 32 |
# File 'lib/bstat2google.rb', line 29 def initialize(attrs = {}) attrs.each {|k,v| self.send("#{k}=", v)} @rest_client = RestClient unless rest_client end |
Instance Attribute Details
#auth_token ⇒ Object
Returns the value of attribute auth_token.
28 29 30 |
# File 'lib/bstat2google.rb', line 28 def auth_token @auth_token end |
#end_point ⇒ Object
Returns the value of attribute end_point.
28 29 30 |
# File 'lib/bstat2google.rb', line 28 def end_point @end_point end |
#rest_client ⇒ Object
Returns the value of attribute rest_client.
28 29 30 |
# File 'lib/bstat2google.rb', line 28 def rest_client @rest_client end |
Instance Method Details
#get(url, options = {}) ⇒ Object
33 34 35 |
# File 'lib/bstat2google.rb', line 33 def get(url, = {}) rest_client.get(url, ) end |