Class: RPath::At
- Inherits:
-
VertexExpression
- Object
- Expression
- VertexExpression
- RPath::At
- Defined in:
- lib/rpath/expressions.rb
Overview
Given a prior expression producing vertex array A, evaluates to the vertex in A at a given index.
Instance Method Summary collapse
-
#initialize(prior, index) ⇒ At
constructor
A new instance of At.
- #to_s ⇒ String
Methods inherited from VertexExpression
#[], #adjacent, #content, #method_missing
Methods inherited from Expression
Constructor Details
#initialize(prior, index) ⇒ At
Returns a new instance of At.
264 265 266 267 268 |
# File 'lib/rpath/expressions.rb', line 264 def initialize(prior, index) super() @prior = prior @index = index end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RPath::VertexExpression
Instance Method Details
#to_s ⇒ String
271 272 273 |
# File 'lib/rpath/expressions.rb', line 271 def to_s "#{@prior}[#{@index}]" end |