Guest User

Untitled

a guest
Oct 23rd, 2018
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. @Entity
  2. @Table(name = "USER")
  3. @JsonIdentityInfo(generator = ObjectIdGenerators.PropertyGenerator.class, property = "id", scope = User.class)
  4. public class User extends AbstractValueObject {
  5. private Integer id;
  6. private String name;
  7. .....
  8. }
  9.  
  10. public class Load extends AbstractValueObject {
  11. private Integer id;
  12. private User postedBy;
  13. }
  14.  
  15. [
  16. {
  17. "id" : 1,
  18. "postedBy" : {
  19. "id":1,
  20. "name":"SOF"
  21. }
  22. },
  23. {
  24. "id" : 1,
  25. "postedBy" : 1
  26. }
  27. ]
Add Comment
Please, Sign In to add comment