Class: ColumnChartDecorator

Inherits:
ChartDecorator show all
Defined in:
lib/chart_decorator.rb

Overview

a concrete decorator

Instance Method Summary collapse

Constructor Details

#initialize(real_chart) ⇒ ColumnChartDecorator

Returns a new instance of ColumnChartDecorator.



40
41
42
43
# File 'lib/chart_decorator.rb', line 40

def initialize(real_chart)
  super(real_chart)
  @features = "Column Chart"
end

Instance Method Details

#drawObject

override the details method to include the description of the extra feature and its corresponding price



46
47
48
# File 'lib/chart_decorator.rb', line 46

def draw
  return @features+"."+@real_chart.draw
end