Class: LogentriesPullApi::Client
- Inherits:
-
Object
- Object
- LogentriesPullApi::Client
- Defined in:
- lib/logentries_pull_api/client.rb
Instance Attribute Summary collapse
-
#account_key ⇒ Object
readonly
Returns the value of attribute account_key.
-
#log_key ⇒ Object
readonly
Returns the value of attribute log_key.
-
#log_set_key ⇒ Object
readonly
Returns the value of attribute log_set_key.
Instance Method Summary collapse
- #get(options = {}) ⇒ Object
-
#initialize(account_key, log_set_key, log_key) ⇒ Client
constructor
A new instance of Client.
Constructor Details
#initialize(account_key, log_set_key, log_key) ⇒ Client
Returns a new instance of Client.
11 12 13 14 15 |
# File 'lib/logentries_pull_api/client.rb', line 11 def initialize(account_key, log_set_key, log_key) @account_key = account_key @log_set_key = log_set_key @log_key = log_key end |
Instance Attribute Details
#account_key ⇒ Object (readonly)
Returns the value of attribute account_key.
9 10 11 |
# File 'lib/logentries_pull_api/client.rb', line 9 def account_key @account_key end |
#log_key ⇒ Object (readonly)
Returns the value of attribute log_key.
9 10 11 |
# File 'lib/logentries_pull_api/client.rb', line 9 def log_key @log_key end |
#log_set_key ⇒ Object (readonly)
Returns the value of attribute log_set_key.
9 10 11 |
# File 'lib/logentries_pull_api/client.rb', line 9 def log_set_key @log_set_key end |
Instance Method Details
#get(options = {}) ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/logentries_pull_api/client.rb', line 18 def get( = {}) response = fetch_response_from assemble_uri() raise LogentriesPullApi::Error, response['reason'] if response.is_a? Hash response end |