Class: Tinge::Color

Inherits:
Object
  • Object
show all
Defined in:
lib/tinge/color.rb

Instance Method Summary collapse

Constructor Details

#initialize(text) ⇒ Color

Returns a new instance of Color.



5
6
7
# File 'lib/tinge/color.rb', line 5

def initialize(text)
  @text = text
end

Instance Method Details

#add_sighting(node, parent = nil) ⇒ Object



9
10
11
# File 'lib/tinge/color.rb', line 9

def add_sighting(node, parent = nil)
  sightings << Sighting.new(self, node, parent)
end

#sightingsObject



13
14
15
# File 'lib/tinge/color.rb', line 13

def sightings
  @sightings ||= []
end