Class: ApexCharts::Charts::BaseChart
- Inherits:
-
Object
- Object
- ApexCharts::Charts::BaseChart
- Includes:
- Utils::Hash
- Defined in:
- lib/apex_charts/charts/base_chart.rb
Direct Known Subclasses
BubbleChart, CartesianChart, HeatmapChart, MixedCharts, PolarChart, RadarChart
Instance Attribute Summary collapse
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#sample ⇒ Object
readonly
Returns the value of attribute sample.
-
#series ⇒ Object
readonly
Returns the value of attribute series.
Instance Method Summary collapse
- #chart_type ⇒ Object
-
#initialize(data, options = {}) ⇒ BaseChart
constructor
A new instance of BaseChart.
- #render ⇒ Object
Methods included from Utils::Hash
camelize, camelize_keys, deep_merge
Constructor Details
#initialize(data, options = {}) ⇒ BaseChart
Returns a new instance of BaseChart.
9 10 11 12 |
# File 'lib/apex_charts/charts/base_chart.rb', line 9 def initialize(data, ={}) @series = build_series(data) @options = () end |
Instance Attribute Details
#options ⇒ Object (readonly)
Returns the value of attribute options.
7 8 9 |
# File 'lib/apex_charts/charts/base_chart.rb', line 7 def @options end |
#sample ⇒ Object (readonly)
Returns the value of attribute sample.
7 8 9 |
# File 'lib/apex_charts/charts/base_chart.rb', line 7 def sample @sample end |
#series ⇒ Object (readonly)
Returns the value of attribute series.
7 8 9 |
# File 'lib/apex_charts/charts/base_chart.rb', line 7 def series @series end |
Instance Method Details
#chart_type ⇒ Object
18 |
# File 'lib/apex_charts/charts/base_chart.rb', line 18 def chart_type; end |
#render ⇒ Object
14 15 16 |
# File 'lib/apex_charts/charts/base_chart.rb', line 14 def render ApexCharts::Renderer.render() end |