Class: Kestrel::Client::Namespace
- Defined in:
- lib/kestrel/client/namespace.rb
Instance Attribute Summary
Attributes inherited from Proxy
Instance Method Summary collapse
- #get(key, *args) ⇒ Object
-
#initialize(namespace, client) ⇒ Namespace
constructor
A new instance of Namespace.
- #set(key, *args) ⇒ Object
Methods inherited from Proxy
Constructor Details
#initialize(namespace, client) ⇒ Namespace
Returns a new instance of Namespace.
4 5 6 7 |
# File 'lib/kestrel/client/namespace.rb', line 4 def initialize(namespace, client) @namespace = namespace super(client) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Kestrel::Client::Proxy
Instance Method Details
#get(key, *args) ⇒ Object
9 10 11 |
# File 'lib/kestrel/client/namespace.rb', line 9 def get(key, *args) client.get(namespace(key), *args) end |
#set(key, *args) ⇒ Object
13 14 15 |
# File 'lib/kestrel/client/namespace.rb', line 13 def set(key, *args) client.set(namespace(key), *args) end |