Module: SVG::ArrayMixin

Includes:
Enumerable
Included in:
Anchor, Group, Picture
Defined in:
lib/ruby-svg/misc.rb

Overview

#

ArrayMixin Module

Instance Method Summary collapse

Instance Method Details

#<<(other) ⇒ Object



57
58
59
# File 'lib/ruby-svg/misc.rb', line 57

def <<(other)
  array << other
end

#[](index) ⇒ Object



49
50
51
# File 'lib/ruby-svg/misc.rb', line 49

def [](index)
  array[index]
end

#[]=(index, value) ⇒ Object



53
54
55
# File 'lib/ruby-svg/misc.rb', line 53

def []=(index, value)
  array[index] = value
end

#clearObject



61
62
63
# File 'lib/ruby-svg/misc.rb', line 61

def clear
  array.clear
end

#each(&block) ⇒ Object



73
74
75
# File 'lib/ruby-svg/misc.rb', line 73

def each(&block)
  array.each(&block)
end

#firstObject



65
66
67
# File 'lib/ruby-svg/misc.rb', line 65

def first
  array.first
end

#lastObject



69
70
71
# File 'lib/ruby-svg/misc.rb', line 69

def last
  array.last
end