Class: CloudSesame::Query::AST::Abstract::Operator
- Inherits:
-
Object
- Object
- CloudSesame::Query::AST::Abstract::Operator
- Defined in:
- lib/cloud_sesame/query/ast/abstract/operator.rb
Direct Known Subclasses
Constant Summary collapse
- SYMBOL =
nil
Instance Attribute Summary collapse
-
#context ⇒ Object
readonly
Returns the value of attribute context.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
- #boost ⇒ Object
-
#initialize(context, options = {}) ⇒ Operator
constructor
A new instance of Operator.
- #symbol ⇒ Object
Constructor Details
#initialize(context, options = {}) ⇒ Operator
Returns a new instance of Operator.
10 11 12 13 |
# File 'lib/cloud_sesame/query/ast/abstract/operator.rb', line 10 def initialize(context, = {}) @context = context = end |
Instance Attribute Details
#context ⇒ Object (readonly)
Returns the value of attribute context.
8 9 10 |
# File 'lib/cloud_sesame/query/ast/abstract/operator.rb', line 8 def context @context end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
8 9 10 |
# File 'lib/cloud_sesame/query/ast/abstract/operator.rb', line 8 def end |
Instance Method Details
#boost ⇒ Object
15 16 17 |
# File 'lib/cloud_sesame/query/ast/abstract/operator.rb', line 15 def boost " boost=#{ options[:boost] }" if [:boost] end |
#symbol ⇒ Object
19 20 21 |
# File 'lib/cloud_sesame/query/ast/abstract/operator.rb', line 19 def symbol self.class::SYMBOL end |