code: public static String createJquery(Chart<?> chart, String divId, String javaScriptVar) {
          StringBuilder builder = new StringBuilder();
          builder.append("$(document).ready(function(){\r\n");
          if (javaScriptVar != null) {
              builder.append("   var ").append(javaScriptVar).append("=");
          }
          builder.append("   $.jqplot('").append(divId).append("', ");
          builder.append(chart.getChartData().toJsonString());
          builder.append(", ");
          builder.append(jqPlotToJson(chart.getChartConfiguration()));
          builder.append(");\r\n");
          builder.append("});\r\n");
          return builder.toString();
      }
docs: Cria um comando jquery
  @param chart Chart
  @param divId id of element div
  @param javaScriptVar javascript variable
  @return jquery javascript