Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » NatTable » EventList.removeAll throws IndexOutOfBoundsException
EventList.removeAll throws IndexOutOfBoundsException [message #947871] Wed, 17 October 2012 14:26 Go to next message
Michi Classen is currently offline Michi ClassenFriend
Messages: 36
Registered: March 2012
Member
Using eventList.removeAll(List<Object> elements) throws an IndexOutOfBoundsException, although the given elements are contained in the eventList. Why this exception is thrown and how I can avoid this errorneous behaviour?
Re: EventList.removeAll throws IndexOutOfBoundsException [message #947910 is a reply to message #947871] Wed, 17 October 2012 15:11 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2902
Registered: July 2012
Senior Member
Could you provide the stacktrace? And maybe an example?
Re: EventList.removeAll throws IndexOutOfBoundsException [message #948675 is a reply to message #947910] Thu, 18 October 2012 08:58 Go to previous messageGo to next message
Michi Classen is currently offline Michi ClassenFriend
Messages: 36
Registered: March 2012
Member
The event list is represented as a tree list. The path of the tree list has a depth of 3. The problem is, that the removeAll() function removes the elements like a list ignoring the parent/child relations of the element.

Using the remove() function of the event list the programmer has to ensure, that at first all child elements have to remove and then the parents! Otherwise an IndexOutOfBoundsException is called.

Re: EventList.removeAll throws IndexOutOfBoundsException [message #948688 is a reply to message #948675] Thu, 18 October 2012 09:09 Go to previous message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2902
Registered: July 2012
Senior Member
Well if that's code of the EventList, than this is the wrong place to talk about. EventList is part of GlazedLists. NatTable only uses GlazedLists in the GlazedLists extension.

There are also some other issues regarding GlazedLists we had to take care of. Especially dealing with trees. AFAIK GlazedLists 1.9 isn't officially released yet. Maybe it will fix some things.
Previous Topic:Click on column header (select) gives an NullPointerException
Next Topic:Does anyone has an example for Date Picker in NatTable?
Goto Forum:
  


Current Time: Thu Apr 25 20:28:40 GMT 2024

Powered by FUDForum. Page generated in 0.03035 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top