Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Customizing FacetChart and ERROR log ... collides with ID of existing object

    Hi, our goals are to
    1) hide legend rectangle line (e.g. using color="#ffffff")
    2) show scatter lines without shadow.
    3) frequently actualize the chart data in extra function (this demo contains it in the same function)

    So I’ve extended the enterprise showcase ScatterPlotChart with an update function, called as updateChart(chart); before creating layout.
    Code:
    private void updateChart(FacetChart chart) {
    	DrawRect rect = new DrawRect();
    	rect.setLineColor("#ffffff");
    	chart.setLegendSwatchProperties(rect);
    
    	DrawLine line = chart.getDataLineProperties();
    	line.setShadow(new Shadow());
    	chart.setDataLineProperties(line);
    
    	chart.setData(ScatterPlotChartData.getData()); //We would like to change our data later.
    }
    It works as shown in attached png. But there are some error rows in log about exceptions, what is wrong please?

    [ERROR] [client] - 12:49:46.714:KUP4:WARN:Log:ClassFactory.addGlobalID: ID:'isc_DrawRect_1' for object '[DrawRect ID:isc_DrawRect_1]' collides with ID of existing object '[DrawRect ID:isc_DrawRect_1]'. The global reference to this object will be replaced
    [ERROR] [client] - 12:49:46.939:KUP4:WARN:Log:ClassFactory.addGlobalID: ID:'isc_DrawLine_1' for object '[DrawCurve ID:isc_DrawLine_1]' collides with ID of existing object '[DrawLine ID:isc_DrawLine_1]'. The global reference to this object will be replaced

    Downloaded trial version for EE Charting:
    SmartGWT Version: 4.0p BuildDate: Mon Dec 02 19:51:00 CET 2013

    Regards
    Béla

    PS: Isomorphic! Thank you very much for the useful answers, tips and bug fixes for my previous questions.
    After development based on following threads we are testing now these: 28652, 28473, 28246. So I can post about our results respectively later.
    Attached Files
    Last edited by bnagwt; 5 Dec 2013, 05:34.

    #2
    We'll check on these warnings, but if you're both supplying a new dataset and making major changes to visual appearance, the simplest thing is to create a new FacetChart.

    Comment


      #3
      Thanks for the tip. I have reduced our goals to 1) and 2) temporary.

      I give here the previously missed more detailed information about this case. We would like to make only once these changes to visual appearance. So this updateChart() is called only the first time (without chart.setData(...) now). I tried to call it immediate after final FacetChart chart = new FacetChart(); but there are the log errors. Thus the chart is created only at once with its changed properties. Should I set some ID values too?

      These are the detailed messages in Log, caused by layout.draw(); in ScatterPlotChart?

      10:49:21.926 [ERROR] [client] 10:49:21.924:KUP2:WARN:Log:ClassFactory.addGlobalID: ID:'isc_DrawRect_0' for object '[DrawRect ID:isc_DrawRect_0]' collides with ID of existing object '[DrawRect ID:isc_DrawRect_0]'. The global reference to this object will be replaced

      com.smartgwt.client.core.JsObject$SGWT_WARN: 10:49:21.924:KUP2:WARN:Log:ClassFactory.addGlobalID: ID:'isc_DrawRect_0' for object '[DrawRect ID:isc_DrawRect_0]' collides with ID of existing object '[DrawRect ID:isc_DrawRect_0]'. The global reference to this object will be replaced
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
      at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:105)
      at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
      at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
      at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:338)
      at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:219)
      at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
      at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)
      at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:299)
      at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107)
      at com.smartgwt.client.widgets.BaseWidget.draw(BaseWidget.java)
      at . . .ScatterPlotChart.<init>(ScatterPlotChart.java:82)

      10:49:22.164 [ERROR] [client] 10:49:22.162:KUP2:WARN:Log:ClassFactory.addGlobalID: ID:'isc_DrawLine_1' for object '[DrawPath ID:isc_DrawLine_1]' collides with ID of existing object '[DrawLine ID:isc_DrawLine_1]'. The global reference to this object will be replaced

      com.smartgwt.client.core.JsObject$SGWT_WARN: 10:49:22.162:KUP2:WARN:Log:ClassFactory.addGlobalID: ID:'isc_DrawLine_1' for object '[DrawPath ID:isc_DrawLine_1]' collides with ID of existing object '[DrawLine ID:isc_DrawLine_1]'. The global reference to this object will be replaced
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
      at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:105)
      at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
      at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
      at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:338)
      at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:219)
      at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
      at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)
      at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:299)
      at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107)
      at com.smartgwt.client.widgets.BaseWidget.draw(BaseWidget.java)
      at . . .ScatterPlotChart.<init>(ScatterPlotChart.java:82)

      As mentioned, our code works OK even for Goal 3 too (simulating something like task manager), but these exception can show also some of our constructing failure. Please let me know, if you find the reason or the fixes.

      Comment

      Working...
      X