Class: Rexle::Elements
Overview
– end of element –
Instance Method Summary collapse
- #[](i) ⇒ Object
- #each(&blk) ⇒ Object
-
#initialize(elements = []) ⇒ Elements
constructor
A new instance of Elements.
- #to_a ⇒ Object
Constructor Details
#initialize(elements = []) ⇒ Elements
Returns a new instance of Elements.
593 594 595 596 |
# File 'lib/rexle.rb', line 593 def initialize(elements=[]) super() @elements = elements end |
Instance Method Details
#[](i) ⇒ Object
598 599 600 |
# File 'lib/rexle.rb', line 598 def [](i) @elements[i-1] end |
#each(&blk) ⇒ Object
602 |
# File 'lib/rexle.rb', line 602 def each(&blk) @elements.each(&blk) end |
#to_a ⇒ Object
603 |
# File 'lib/rexle.rb', line 603 def to_a() @elements end |