Closed mikernet closed 5 years ago
Also this is what it says in the online documentation for TreeBag
NOTE: the bag implementation is currently wrong! ?????
What's going on here????? ! (lol)
I noticed there is some code as well in the user guide that supposedly throws exceptions for the treebag. @sestoft Can you please let me know if the treebag is indeed broken, as the biggest reason I wanted to use this library was for a index-accessible bag with O(log n) insert and retrieval time so this might be a bit of a bummer. I may be able to use a TreeSet instead - are there any known issues with that class?
In what sense should TreeBag be "broken"?
On 15Nov17, 21:34, "Mike Marynowski" notifications@github.com<mailto:notifications@github.com> wrote:
I noticed there is some code as well in the user guide that supposedly throws exceptions for the treebag. @sestofthttps://github.com/sestoft Can you please let me know if the treebag is indeed broken, as the biggest reason I wanted to use this library was for a index-accessible bag with O(log n) insert and retrieval time so this might be a bit of a bummer. I may be able to use a TreeSet instead - are there any known issues with that class?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/sestoft/C5/issues/64#issuecomment-344719801, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAsoEMkR_I_xmE4cOopuBZdpvrUuB4sIks5s20rBgaJpZM4QaERc.
From your user guide examples: https://github.com/sestoft/C5/blob/master/C5.UserGuideExamples/TreebagBug20091113.cs
Also line 1338 in redblacktreebag.cs starts like this:
#warning for bag implementation: count is wrong
if (ActiveEvents != 0)
raiseForUpdate(item, olditem, 1);
return true;
Not entirely sure what to make of that
This was fixed on 2010-12-17.
On 15Nov17, 21:37, "Mike Marynowski" notifications@github.com<mailto:notifications@github.com> wrote:
From your user guide examples: https://github.com/sestoft/C5/blob/master/C5.UserGuideExamples/TreebagBug20091113.cs
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/sestoft/C5/issues/64#issuecomment-344720551, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAsoEFIcbzwKdlWXfbO8WEDSHgoL3wP0ks5s20tvgaJpZM4QaERc.
If you do not use the events raised by updates to the collection you need not worry.
On 15Nov17, 21:40, "Mike Marynowski" notifications@github.com<mailto:notifications@github.com> wrote:
Also line 1338 in redblacktreebag.cs starts like this:
if (ActiveEvents != 0)
raiseForUpdate(item, olditem, 1);
return true;
Not entirely sure what to make of that
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/sestoft/C5/issues/64#issuecomment-344721419, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAsoEHO5Wn2E4vadz5cmdhu-UITA-8H6ks5s20wsgaJpZM4QaERc.
I definitely will be - the events are the real selling point for this library as I need to track a diff of the collections as they change so I can push only the changes to a database.
Oh! In this case the multiplicity will be wrong (always 1) in the ItemCountEventArgs
This value is described like this on p 136 of the 2008 manual: "Read-only field int Count is the multiplicity with which the insertion or deletion occurred."
Sorry about that.
On 15Nov17, 21:47, "Mike Marynowski" notifications@github.com<mailto:notifications@github.com> wrote:
I definitely will be, the events are the real selling point for this library as I need to track a diff of the collections as they change so I can push only the changes to a database.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/sestoft/C5/issues/64#issuecomment-344723387, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAsoECGK6YSVY5YPKSgoAJaumY9IuZeeks5s203ygaJpZM4QaERc.
Okay thank you very much.
What is the state of this project?
The #warning tags included by the devs in the source code indicating incorrect behavior and suspicions isn't particularly confidence inspiring given there haven't been any updates in a long time.