Class: XPath::Expression

Inherits:
Object
  • Object
show all
Includes:
DSL::ExpressionLevel
Defined in:
lib/xpath/expression.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Methods included from DSL::ExpressionLevel

#and, #equals, #inverse, #next_sibling, #normalize, #one_of, #or, #string_literal, #union, #where

Methods included from DSL::TopLevel

#anywhere, #attr, #axis, #child, #contains, #css, #descendant, #name, #starts_with, #string, #text

Constructor Details

- (Expression) initialize(expression, *arguments)



6
7
8
9
# File 'lib/xpath/expression.rb', line 6

def initialize(expression, *arguments)
  @expression = expression
  @arguments = arguments
end

Instance Attribute Details

- (Object) arguments

Returns the value of attribute arguments



3
4
5
# File 'lib/xpath/expression.rb', line 3

def arguments
  @arguments
end

- (Object) expression

Returns the value of attribute expression



3
4
5
# File 'lib/xpath/expression.rb', line 3

def expression
  @expression
end

Instance Method Details

- (Object) current



11
12
13
# File 'lib/xpath/expression.rb', line 11

def current
  self
end

- (Object) to_xpath Also known as: to_s



15
16
17
# File 'lib/xpath/expression.rb', line 15

def to_xpath
  Renderer.render(self)
end