Class: SearchKey
- Inherits:
-
Struct
- Object
- Struct
- SearchKey
- Defined in:
- lib/engine/app/lib/commands/search_key.rb
Instance Attribute Summary collapse
-
#backend ⇒ Object
Returns the value of attribute backend.
-
#key ⇒ Object
Returns the value of attribute key.
Instance Method Summary collapse
Instance Attribute Details
#backend ⇒ Object
Returns the value of attribute backend
1 2 3 |
# File 'lib/engine/app/lib/commands/search_key.rb', line 1 def backend @backend end |
#key ⇒ Object
Returns the value of attribute key
1 2 3 |
# File 'lib/engine/app/lib/commands/search_key.rb', line 1 def key @key end |
Instance Method Details
#result ⇒ Object
2 3 4 |
# File 'lib/engine/app/lib/commands/search_key.rb', line 2 def result backend.keys(key).map{|found| {key: found, value: backend.get(found)} } end |