computerluca / lambdaj

Automatically exported from code.google.com/p/lambdaj
1 stars 0 forks source link

group() blows up #27

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Unpack the attached eclipse project
2. Run the test inside of Eclipse

What is the expected output? What do you see instead?
I expect the test to complete.
Instead I get a failure:

java.lang.RuntimeException: java.lang.NoSuchMethodException:
FeldError.-2147483646()
    at
ch.lambdaj.util.IntrospectionUtil.getPlainPropertyValue(IntrospectionUtil.java:5
2)
    at
ch.lambdaj.util.IntrospectionUtil.getBooleanPropertyValue(IntrospectionUtil.java
:44)
    at
ch.lambdaj.util.IntrospectionUtil.getPropertyValue(IntrospectionUtil.java:36)
    at
ch.lambdaj.group.StringGroupCondition.getGroupValue(StringGroupCondition.java:41
)
    at ch.lambdaj.group.GroupImpl.addItem(GroupImpl.java:30)
    at ch.lambdaj.group.Groups.group(Groups.java:58)
    at ch.lambdaj.group.Groups.group(Groups.java:46)
    at LambdajBarfsTest.lambdajBarf(LambdajBarfsTest.java:24)

What version of the product are you using? On what operating system?
2.1 - lambdaj
Linux - SUSE 10.x
Java 1.6

Please provide any additional information below.

Original issue reported on code.google.com by rblu...@gmail.com on 8 Mar 2010 at 11:59

GoogleCodeExporter commented 9 years ago
I am sorry, but the provided zip archive seems to be empty. 
Could you please check and reattach it or even send it to me via email?

Thank you
Mario

Original comment by mario.fu...@gmail.com on 9 Mar 2010 at 8:12

GoogleCodeExporter commented 9 years ago

Original comment by rblu...@gmail.com on 15 Mar 2010 at 6:05

Attachments:

GoogleCodeExporter commented 9 years ago
Yeah I forgot to use -r on the zip command. 

Original comment by rblu...@gmail.com on 15 Mar 2010 at 6:06

GoogleCodeExporter commented 9 years ago
It seams you forgot to use the by() method to create the group condition. It 
should
work as it follows:

Group<FeldError> groupedByFeld = group(feldErrors, 
by(on(FeldError.class).getFeld()));

Please confirm that it works in that way so I can close this issue.

Thank you
Mario

Original comment by mario.fu...@gmail.com on 15 Mar 2010 at 9:48

GoogleCodeExporter commented 9 years ago
Confirmed that it does work correctly when by is used.
User error.
Thank you. 

Original comment by rblu...@gmail.com on 15 Mar 2010 at 10:23

GoogleCodeExporter commented 9 years ago

Original comment by mario.fu...@gmail.com on 16 Mar 2010 at 8:09