January 2013
Intermediate to advanced
328 pages
7h 14m
English
The meterGauge component visualizes data on a meter gauge display.
A simple definition for a meter gauge to list metric tons per year is shown as follows:
<p:meterGaugeChart id="simple" value="#{meterGaugeController.model}" style="height:250px" />The chart will be rendered as shown in the following screenshot:

The model that binds to the component should be an instance of org.primefaces.model.chart.MeterGaugeChartModel. The definition for the model with the ticks and intervals is given as follows:
List<Number> intervals = new ArrayList<Number>(){{ add(22000); add(55000); add(70000); }}; List<Number> ticks ...Read now
Unlock full access