Module: XPath::DSL::ExpressionLevel
Instance Method Summary
collapse
Methods included from TopLevel
#anywhere, #attr, #axis, #child, #contains, #css, #current, #descendant, #name, #next_sibling, #previous_sibling, #starts_with, #string, #text
Instance Method Details
#and(expression) ⇒ Object
Also known as:
&
87
88
89
|
# File 'lib/xpath/dsl.rb', line 87
def and(expression)
Expression.new(:and, current, expression)
end
|
#equals(expression) ⇒ Object
Also known as:
==
73
74
75
|
# File 'lib/xpath/dsl.rb', line 73
def equals(expression)
Expression.new(:equality, current, expression)
end
|
#inverse ⇒ Object
Also known as:
~
97
98
99
|
# File 'lib/xpath/dsl.rb', line 97
def inverse
Expression.new(:inverse, current)
end
|
#is(expression) ⇒ Object
78
79
80
|
# File 'lib/xpath/dsl.rb', line 78
def is(expression)
Expression.new(:is, current, expression)
end
|
#normalize ⇒ Object
Also known as:
n
106
107
108
|
# File 'lib/xpath/dsl.rb', line 106
def normalize
Expression.new(:normalized_space, current)
end
|
#one_of(*expressions) ⇒ Object
69
70
71
|
# File 'lib/xpath/dsl.rb', line 69
def one_of(*expressions)
Expression.new(:one_of, current, expressions)
end
|
#or(expression) ⇒ Object
Also known as:
|
82
83
84
|
# File 'lib/xpath/dsl.rb', line 82
def or(expression)
Expression.new(:or, current, expression)
end
|
#string_literal ⇒ Object
102
103
104
|
# File 'lib/xpath/dsl.rb', line 102
def string_literal
Expression.new(:string_literal, self)
end
|
#union(*expressions) ⇒ Object
Also known as:
+
92
93
94
|
# File 'lib/xpath/dsl.rb', line 92
def union(*expressions)
Union.new(*[self, expressions].flatten)
end
|
#where(expression) ⇒ Object
Also known as:
[]
64
65
66
|
# File 'lib/xpath/dsl.rb', line 64
def where(expression)
Expression.new(:where, current, expression)
end
|