Class: Querly::Pattern::Expr::Base
- Inherits:
-
Object
- Object
- Querly::Pattern::Expr::Base
show all
- Defined in:
- lib/querly/pattern/expr.rb
Instance Method Summary
collapse
Instance Method Details
#==(other) ⇒ Object
13
14
15
|
# File 'lib/querly/pattern/expr.rb', line 13
def ==(other)
other.class == self.class && other.attributes == attributes
end
|
#=~(pair) ⇒ Object
5
6
7
|
# File 'lib/querly/pattern/expr.rb', line 5
def =~(pair)
test_node(pair.node)
end
|
#attributes ⇒ Object
17
18
19
20
21
|
# File 'lib/querly/pattern/expr.rb', line 17
def attributes
instance_variables.each.with_object({}) do |name, hash|
hash[name] = instance_variable_get(name)
end
end
|
#test_node(node) ⇒ Object
9
10
11
|
# File 'lib/querly/pattern/expr.rb', line 9
def test_node(node)
false
end
|