Class: DynamoidAdvancedWhere::Nodes::NotNode
- Inherits:
-
Object
- Object
- DynamoidAdvancedWhere::Nodes::NotNode
- Extended by:
- Forwardable
- Defined in:
- lib/dynamoid_advanced_where/nodes/not.rb
Instance Attribute Summary collapse
-
#sub_node ⇒ Object
Returns the value of attribute sub_node.
Instance Method Summary collapse
-
#initialize(sub_node:) ⇒ NotNode
constructor
A new instance of NotNode.
- #to_expression ⇒ Object
Methods included from Concerns::SupportsLogicalOr
Methods included from Concerns::SupportsLogicalAnd
Constructor Details
#initialize(sub_node:) ⇒ NotNode
Returns a new instance of NotNode.
31 32 33 34 |
# File 'lib/dynamoid_advanced_where/nodes/not.rb', line 31 def initialize(sub_node:) self.sub_node = sub_node freeze end |
Instance Attribute Details
#sub_node ⇒ Object
Returns the value of attribute sub_node.
25 26 27 |
# File 'lib/dynamoid_advanced_where/nodes/not.rb', line 25 def sub_node @sub_node end |
Instance Method Details
#to_expression ⇒ Object
36 37 38 |
# File 'lib/dynamoid_advanced_where/nodes/not.rb', line 36 def to_expression "NOT(#{sub_node.to_expression})" end |