Re: ObjectModel exception

2007-09-28 Thread Grzegorz Kossakowski
Leszek Gawron pisze: > Grzegorz Kossakowski wrote: >> Leszek Gawron pisze: >> >> Because comparison is made by low-level class like ArrayList that is >> unaware of wrapping objects. >> >> Do you want to say that NativeObjects should be unwrapped always >> whenever they are used in Java code? > > S

Re: ObjectModel exception

2007-09-27 Thread Leszek Gawron
Grzegorz Kossakowski wrote: Leszek Gawron pisze: Grzegorz Kossakowski wrote: Leszek Gawron pisze: Because stack implementation used to maintain local scopes uses some variation of ListArray class that uses equals() when remove() method is called. Just for efficiency I guess that real scope cou

Re: ObjectModel exception

2007-09-26 Thread Joerg Heinicke
On 25.09.2007 15:48 Uhr, Grzegorz Kossakowski wrote: Yep. Contrary to the old OM handling the new one demands equals() method properly implemented for all objects put on OM. What does "properly" mean? I would not enforce the user to implement equals() on every object, so as long as default e

Re: ObjectModel exception

2007-09-26 Thread Grzegorz Kossakowski
Leszek Gawron pisze: > Grzegorz Kossakowski wrote: >> Leszek Gawron pisze: >> >> Because stack implementation used to maintain local scopes uses some >> variation of ListArray class >> that uses equals() when remove() method is called. Just for efficiency >> I guess that real scope could >> be impl

Re: ObjectModel exception

2007-09-26 Thread Leszek Gawron
Grzegorz Kossakowski wrote: Leszek Gawron pisze: Grzegorz Kossakowski wrote: Leszek Gawron pisze: Yep. Contrary to the old OM handling the new one demands equals() method properly implemented for all objects put on OM. Is it something bad? I have no idea :) why such requirement? Because st

Re: ObjectModel exception

2007-09-26 Thread Vadim Gritsenko
Leszek Gawron wrote: Lately I keep getting these: java.lang.ClassCastException: org.mozilla.javascript.NativeObject at com.mobilebox.smart.model.Contractor.equals(Contractor.java:335) at java.util.ArrayList.remove(ArrayList.java:424) Question is why is my entity Contractor equalized

Re: ObjectModel exception

2007-09-26 Thread Grzegorz Kossakowski
Leszek Gawron pisze: > Grzegorz Kossakowski wrote: >> Leszek Gawron pisze: >> >> Yep. Contrary to the old OM handling the new one demands equals() >> method properly implemented for >> all objects put on OM. >> >> Is it something bad? > > I have no idea :) why such requirement? Because stack imp

Re: ObjectModel exception

2007-09-26 Thread Leszek Gawron
Grzegorz Kossakowski wrote: Leszek Gawron pisze: Lately I keep getting these: java.lang.ClassCastException: org.mozilla.javascript.NativeObject at com.mobilebox.smart.model.Contractor.equals(Contractor.java:335) at java.util.ArrayList.remove(ArrayList.java:424) at org.apache.common

Re: ObjectModel exception

2007-09-25 Thread Grzegorz Kossakowski
Leszek Gawron pisze: > Lately I keep getting these: > >> java.lang.ClassCastException: org.mozilla.javascript.NativeObject >> at com.mobilebox.smart.model.Contractor.equals(Contractor.java:335) >> at java.util.ArrayList.remove(ArrayList.java:424) >> at >> org.apache.commons.collections

ObjectModel exception

2007-09-24 Thread Leszek Gawron
Lately I keep getting these: java.lang.ClassCastException: org.mozilla.javascript.NativeObject at com.mobilebox.smart.model.Contractor.equals(Contractor.java:335) at java.util.ArrayList.remove(ArrayList.java:424) at org.apache.commons.collections.map.MultiValueMap.remove