Class: Jerakia::Dsl::Lookup
- Inherits:
-
Object
- Object
- Jerakia::Dsl::Lookup
- Defined in:
- lib/jerakia/dsl/lookup.rb
Instance Attribute Summary collapse
-
#lookup ⇒ Object
Returns the value of attribute lookup.
-
#request ⇒ Object
readonly
Returns the value of attribute request.
-
#scope_object ⇒ Object
readonly
Returns the value of attribute scope_object.
Class Method Summary collapse
Instance Method Summary collapse
-
#confine(*args) ⇒ Object
pass through exposed functions from the main lookup object @api: public.
- #continue ⇒ Object
-
#datasource(name, opts = {}) ⇒ Object
define the data source for the lookup @api: public.
- #exclude(*args) ⇒ Object
-
#initialize(name, request, scope, opts = {}) ⇒ Lookup
constructor
A new instance of Lookup.
- #invalidate ⇒ Object
- #output_filter(*args) ⇒ Object
- #plugin ⇒ Object
- #scope ⇒ Object
- #stop ⇒ Object
Constructor Details
Instance Attribute Details
#lookup ⇒ Object
Returns the value of attribute lookup.
6 7 8 |
# File 'lib/jerakia/dsl/lookup.rb', line 6 def lookup @lookup end |
#request ⇒ Object (readonly)
Returns the value of attribute request.
4 5 6 |
# File 'lib/jerakia/dsl/lookup.rb', line 4 def request @request end |
#scope_object ⇒ Object (readonly)
Returns the value of attribute scope_object.
5 6 7 |
# File 'lib/jerakia/dsl/lookup.rb', line 5 def scope_object @scope_object end |
Class Method Details
.evaluate(name, request, scope, opts, &block) ⇒ Object
14 15 16 17 18 |
# File 'lib/jerakia/dsl/lookup.rb', line 14 def self.evaluate(name, request, scope, opts, &block) lookup_block = new(name, request, scope, opts) lookup_block.instance_eval &block return lookup_block.lookup end |
Instance Method Details
#confine(*args) ⇒ Object
pass through exposed functions from the main lookup object @api: public
28 29 30 |
# File 'lib/jerakia/dsl/lookup.rb', line 28 def confine(*args) lookup.confine(*args) end |
#continue ⇒ Object
48 49 50 |
# File 'lib/jerakia/dsl/lookup.rb', line 48 def continue lookup.continue end |
#datasource(name, opts = {}) ⇒ Object
define the data source for the lookup @api: public
22 23 24 |
# File 'lib/jerakia/dsl/lookup.rb', line 22 def datasource(name, opts = {}) lookup.datasource = { :name => name, :opts => opts } end |
#exclude(*args) ⇒ Object
36 37 38 |
# File 'lib/jerakia/dsl/lookup.rb', line 36 def exclude(*args) lookup.exclude(*args) end |
#invalidate ⇒ Object
40 41 42 |
# File 'lib/jerakia/dsl/lookup.rb', line 40 def invalidate lookup.invalidate end |
#output_filter(*args) ⇒ Object
52 53 54 |
# File 'lib/jerakia/dsl/lookup.rb', line 52 def output_filter(*args) lookup.output_filter(*args) end |
#plugin ⇒ Object
56 57 58 |
# File 'lib/jerakia/dsl/lookup.rb', line 56 def plugin lookup.plugin end |
#scope ⇒ Object
32 33 34 |
# File 'lib/jerakia/dsl/lookup.rb', line 32 def scope @scope_object.value end |
#stop ⇒ Object
44 45 46 |
# File 'lib/jerakia/dsl/lookup.rb', line 44 def stop lookup.stop end |