com.googlecode.wickedcharts.highcharts.options.util
Class OptionsUtil

java.lang.Object
  extended by com.googlecode.wickedcharts.highcharts.options.util.OptionsUtil

public class OptionsUtil
extends Object


Method Summary
 void copyRenderTo(Options from, Options to)
          Copies the renderTo configuration from one Options object to another.
static Axis getAxisWithWickedChartsId(Options options, int wickedChartsId)
           
static OptionsUtil getInstance()
           
static Point getPointWithWickedChartsId(Options options, int wickedChartsId)
          Retrieves the Point object with the given wickedChartsId from the given Options object.
static Series<?> getSeriesWithWickedChartsId(Options options, int wickedChartsId)
          Retrieves the Series object with the given wickedChartsId from the given Options object.
static boolean needsExportingJs(Options options)
          Checks if the specified Options object needs the javascript file "exporting.js" to work properly.
static boolean needsHighchartsMoreJs(Options options)
          Checks if the specified Options object needs the javascript file "highcharts-more.js" to work properly.
 void setChartEventsLoad(Options options, Function function)
          Null-safe setter for the chart.events.load configuration.
 void setRenderTo(Options options, String renderTo)
          Null-safe setter for the renderTo configuration.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static OptionsUtil getInstance()

copyRenderTo

public void copyRenderTo(Options from,
                         Options to)
Copies the renderTo configuration from one Options object to another. Null-safe.


setRenderTo

public void setRenderTo(Options options,
                        String renderTo)
Null-safe setter for the renderTo configuration.


setChartEventsLoad

public void setChartEventsLoad(Options options,
                               Function function)
Null-safe setter for the chart.events.load configuration.


needsHighchartsMoreJs

public static boolean needsHighchartsMoreJs(Options options)
Checks if the specified Options object needs the javascript file "highcharts-more.js" to work properly. This method can be called by GUI components to determine whether the javascript file has to be included in the page or not.

Parameters:
options - the Options object to analyze
Returns:
true, if "highcharts-more.js" is needed to render the options, false if not

needsExportingJs

public static boolean needsExportingJs(Options options)
Checks if the specified Options object needs the javascript file "exporting.js" to work properly. This method can be called by GUI components to determine whether the javascript file has to be included in the page or not.

Parameters:
options - the Options object to analyze
Returns:
true, if "exporting.js" is needed to render the options, false if not

getSeriesWithWickedChartsId

public static Series<?> getSeriesWithWickedChartsId(Options options,
                                                    int wickedChartsId)
Retrieves the Series object with the given wickedChartsId from the given Options object. Returns null if a Series with the given ID does not exist.


getPointWithWickedChartsId

public static Point getPointWithWickedChartsId(Options options,
                                               int wickedChartsId)
Retrieves the Point object with the given wickedChartsId from the given Options object. Returns null if a Point with the given ID does not exist.


getAxisWithWickedChartsId

public static Axis getAxisWithWickedChartsId(Options options,
                                             int wickedChartsId)


Copyright © 2013. All Rights Reserved.