exception - JFreeChart throws java.util.ConcurrentModificationException -


i using jfreechat in order draw charts java. actual drawing part of quite big project, not allow me include more code. me seems exception thrown directly
jfreechart component. appreciate if out. there way track down in more detail exception thrown? read exception thrown in cases iteration of lists, while removing elements same list @ same time (which not doing right now).

exception in thread "awt-eventqueue-0" java.util.concurrentmodificationexception     @ java.util.arraylist$itr.checkforcomodification(arraylist.java:901)     @ java.util.arraylist$itr.next(arraylist.java:851)     @ org.jfree.chart.plot.xyplot.drawannotations(xyplot.java:3972)     @ org.jfree.chart.plot.xyplot.draw(xyplot.java:3339)     @ org.jfree.chart.jfreechart.draw(jfreechart.java:1229)     @ org.jfree.chart.chartpanel.paintcomponent(chartpanel.java:1624)     @ javax.swing.jcomponent.paint(jcomponent.java:1056)     @ javax.swing.jcomponent.painttooffscreen(jcomponent.java:5210)     @ javax.swing.repaintmanager$paintmanager.paintdoublebuffered(repaintmanager.java:1579)     @ javax.swing.repaintmanager$paintmanager.paint(repaintmanager.java:1502)     @ javax.swing.bufferstrategypaintmanager.paint(bufferstrategypaintmanager.java:306)     @ javax.swing.repaintmanager.paint(repaintmanager.java:1272)     @ javax.swing.jcomponent._paintimmediately(jcomponent.java:5158)     @ javax.swing.jcomponent.paintimmediately(jcomponent.java:4969)     @ javax.swing.repaintmanager$4.run(repaintmanager.java:831)     @ javax.swing.repaintmanager$4.run(repaintmanager.java:814)     @ java.security.accesscontroller.doprivileged(native method)     @ java.security.protectiondomain$javasecurityaccessimpl.dointersectionprivilege(protectiondomain.java:80)     @ javax.swing.repaintmanager.paintdirtyregions(repaintmanager.java:814)     @ javax.swing.repaintmanager.paintdirtyregions(repaintmanager.java:789)     @ javax.swing.repaintmanager.prepaintdirtyregions(repaintmanager.java:738)     @ javax.swing.repaintmanager.access$1200(repaintmanager.java:64)     @ javax.swing.repaintmanager$processingrunnable.run(repaintmanager.java:1732)     @ java.awt.event.invocationevent.dispatch(invocationevent.java:311)     @ java.awt.eventqueue.dispatcheventimpl(eventqueue.java:756)     @ java.awt.eventqueue.access$500(eventqueue.java:97)     @ java.awt.eventqueue$3.run(eventqueue.java:709)     @ java.awt.eventqueue$3.run(eventqueue.java:703)     @ java.security.accesscontroller.doprivileged(native method)     @ java.security.protectiondomain$javasecurityaccessimpl.dointersectionprivilege(protectiondomain.java:80)     @ java.awt.eventqueue.dispatchevent(eventqueue.java:726)     @ java.awt.eventdispatchthread.pumponeeventforfilters(eventdispatchthread.java:201)     @ java.awt.eventdispatchthread.pumpeventsforfilter(eventdispatchthread.java:116)     @ java.awt.eventdispatchthread.pumpeventsforhierarchy(eventdispatchthread.java:105)     @ java.awt.eventdispatchthread.pumpevents(eventdispatchthread.java:101)     @ java.awt.eventdispatchthread.pumpevents(eventdispatchthread.java:93)     @ java.awt.eventdispatchthread.run(eventdispatchthread.java:82) 

best regards.

the source drawannotations() in version 1.0.19 @ line 3972 seen here; unremarkable , functions correctly. problem can arise if inadvertently make top-level container visible or update plot's dataset on initial thread. resulting update event execute on event dispatch thread, possibly giving rise race condition. swing requires construct , manipulate swing gui objects only on event dispatch thread. if errant code not apparent, try approach shown here detect latent violations.


Comments

Popular posts from this blog

ios - MKAnnotationView layer is not of expected type: MKLayer -

ZeroMQ on Windows, with Qt Creator -

unity3d - Unity SceneManager.LoadScene quits application -