Class: Daytona::Charts::PieChart
- Defined in:
- lib/daytona/common/charts.rb
Instance Attribute Summary collapse
-
#elements ⇒ Array<Daytona::Charts::PieData>
readonly
The pie slices of the chart.
Attributes inherited from Chart
Instance Method Summary collapse
-
#initialize(data) ⇒ PieChart
constructor
A new instance of PieChart.
- #to_h ⇒ Hash<Symbol, Object>
Constructor Details
Instance Attribute Details
#elements ⇒ Array<Daytona::Charts::PieData> (readonly)
Returns The pie slices of the chart.
207 208 209 |
# File 'lib/daytona/common/charts.rb', line 207 def elements @elements end |
Instance Method Details
#to_h ⇒ Hash<Symbol, Object>
217 |
# File 'lib/daytona/common/charts.rb', line 217 def to_h = super.merge(elements: elements.map(&:to_h)) |