Why "pm.newQuery(Employee.class)" and not "pm.newQuery(Employee)" in JDO?

Posted by Dieter Gantz on Stack Overflow See other posts from Stack Overflow or by Dieter Gantz
Published on 2010-03-30T00:50:55Z Indexed on 2010/03/30 0:53 UTC
Read the original article Hit count: 299

Filed under:
|

In this JDO, why is .class needed here?

Query averageSalaryQuery = pm.newQuery(Employee.class);

I would prefer to write this more concise syntax if possible?

Query averageSalaryQuery = pm.newQuery(Employee);

© Stack Overflow or respective owner

Related posts about jdo

Related posts about java