Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Class<?> clazz = Class.forName("com.epam.pre_prod.entity." + name);
- clazz.getDeclaredFields();
- Product product = (Product) clazz.newInstance();
- for (Field field : clazz.getDeclaredFields()) {
- System.out.println(field.isAnnotationPresent(field.getName()));
- System.out.println(field.isAnnotationPresent(Collect.class));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement