Class: RSimperium::Api

Inherits:
Object
  • Object
show all
Defined in:
lib/r_simperium/api.rb

Instance Method Summary collapse

Constructor Details

#initialize(app_id, auth_token, options = {}) ⇒ Api

TODO:

Document

Returns a new instance of Api.



5
6
7
8
9
# File 'lib/r_simperium/api.rb', line 5

def initialize(app_id, auth_token, options={})
  @app_id = app_id
  @token = auth_token
  @options = options
end

Instance Method Details

#[](name) ⇒ Object

TODO:

Document



12
13
14
# File 'lib/r_simperium/api.rb', line 12

def [](name)
  get_item(name)
end

#get_item(name) ⇒ Object

TODO:

Document



17
18
19
# File 'lib/r_simperium/api.rb', line 17

def get_item(name)
  Bucket.new(@app_id, @token, name.to_s, @options)
end