@Override
protected void encodeOptions(FacesContext context, Chart chart) throws IOException {
super.encodeOptions(context, chart);
ResponseWriter writer = context.getResponseWriter();
BubbleChartModel model = (BubbleChartModel) chart.getModel();
writer.write(",showLabels:" + model.isShowLabels());
writer.write(",bubbleGradients:" + model.isBubbleGradients());
writer.write(",bubbleAlpha:" + model.getBubbleAlpha());
if(model.isZoom())
writer.write(",zoom:true");
if(model.isShowDatatip()) {
writer.write(",datatip:true");
if(model.getDatatipFormat() != null)
writer.write(",datatipFormat:\"" + model.getDatatipFormat() + "\"");
}
}