I downloaded Eclipse, Vaadin plugin and created a Vaadin 7 project (7.4.3). I want to create a JPA Entity class. But when I put in @Entity for my entity class, it said “Entity cannot be resolved to a type”
Do you know why?
Thanks
I downloaded Eclipse, Vaadin plugin and created a Vaadin 7 project (7.4.3). I want to create a JPA Entity class. But when I put in @Entity for my entity class, it said “Entity cannot be resolved to a type”
Do you know why?
Thanks
You need to have the Persistence API library in your classpath, as described in
JPAContainer instructions
. In a normal (non-Maven) Vaadin project in Eclipse that would be:
<!-- Java Persistence API -->
<dependency org="org.eclipse.persistence"
name="javax.persistence"
rev="2.1.0"/>
…or the latest version…and of course you need the Persistence API implementation, database driver or engine, etc.