How to annotate fields with @ ID in EJB 3 (JPA) and Hibernate?
•
Java
The title is self explanatory
I'm glad to hear about the solution, thank you
Solution
So far, the method used is shorter than at present:
Reflections r = new Reflections(this.getClass().getPackage().getName()); Set<Field> fields = r.getFieldsAnnotatedWith(Id.class);
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码