Class: OpenHAB::DSL::Sitemaps::ChartBuilder
- Inherits:
-
WidgetBuilder
- Object
- WidgetBuilder
- OpenHAB::DSL::Sitemaps::ChartBuilder
- Defined in:
- lib/openhab/dsl/sitemaps/builder.rb
Overview
Builds a Chart element See www.openhab.org/docs/ui/sitemaps.html#element-type-chart
Constant Summary collapse
- VALID_PERIODS =
Valid #period values
i[h 4h 8h 12h D 2D 3D W 2W M 2M 4M Y].freeze
Instance Attribute Summary collapse
-
#group ⇒ true, ...
writeonly
Show the value of a GroupItem instead of showing a graph for each member (which is the default).
-
#legend ⇒ true, ...
writeonly
Always show the legend, never show the legend, or automatically show the legend if there is more than one series in the chart.
-
#period ⇒ :h, ...
Time axis scale.
-
#refresh ⇒ Numeric?
How often to refresh the chart (in seconds).
-
#service ⇒ String?
The persistence service to use.
-
#y_axis_pattern ⇒ String?
Formatting string for values on the y axis.
Attributes inherited from WidgetBuilder
#icon, #icon_colors, #item, #label, #label_colors, #static_icon, #value_colors, #visibilities
Instance Method Summary collapse
-
#group? ⇒ true, ...
Show the value of a GroupItem instead of showing a graph for each member (which is the default).
-
#legend? ⇒ true, ...
Always show the legend, never show the legend, or automatically show the legend if there is more than one series in the chart.
Methods inherited from WidgetBuilder
#icon_color, #label_color, #value_color, #visibility
Methods included from Core::EntityLookup
#items, #method_missing, #things
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class OpenHAB::Core::EntityLookup
Instance Attribute Details
#group=(value) ⇒ true, ... (writeonly)
Show the value of a GroupItem instead of showing a graph for each member (which is the default).
533 534 535 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 533 def group=(value) @group = value end |
#legend=(value) ⇒ true, ... (writeonly)
Always show the legend, never show the legend, or automatically show the legend if there is more than one series in the chart.
529 530 531 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 529 def legend=(value) @legend = value end |
#period ⇒ :h, ...
Time axis scale
525 526 527 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 525 def period @period end |
#refresh ⇒ Numeric?
How often to refresh the chart (in seconds)
522 523 524 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 522 def refresh @refresh end |
#service ⇒ String?
The persistence service to use
519 520 521 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 519 def service @service end |
#y_axis_pattern ⇒ String?
Formatting string for values on the y axis.
539 540 541 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 539 def y_axis_pattern @y_axis_pattern end |
Instance Method Details
#group? ⇒ true, ...
Show the value of a GroupItem instead of showing a graph for each member (which is the default).
589 590 591 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 589 def group? @group end |
#legend? ⇒ true, ...
Always show the legend, never show the legend, or automatically show the legend if there is more than one series in the chart.
584 585 586 |
# File 'lib/openhab/dsl/sitemaps/builder.rb', line 584 def legend? @legend end |