Advertisement
Guest User

Untitled

a guest
Jan 19th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. @Entity
  2. public class Task {
  3. @Id
  4. @GeneratedValue
  5. private Integer id;
  6.  
  7. private String title;
  8. private String text;
  9. private boolean done;
  10. }
  11.  
  12. @Entity
  13. public class TodolistUser {
  14. @Id
  15. @GeneratedValue
  16. private Integer id;
  17.  
  18. private String login;
  19. private String password;
  20.  
  21. @Autowired
  22. @ElementCollection
  23. private List<Task> tasks;
  24. }
  25.  
  26. @Service
  27. public class TodolistUserService {
  28. @Autowired
  29. private TodolistUserRepository repository;
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement