Guest User

Untitled

a guest
Nov 9th, 2018
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.93 KB | None | 0 0
  1. package com.medium.medium.model;
  2.  
  3. import lombok.EqualsAndHashCode;
  4. import lombok.Getter;
  5. import lombok.Setter;
  6. import lombok.ToString;
  7. import org.springframework.data.annotation.Id;
  8. import org.springframework.data.mongodb.core.index.Indexed;
  9. import org.springframework.data.mongodb.core.mapping.Document;
  10.  
  11. import java.util.List;
  12.  
  13. /**
  14. * Project Name : medium-auth-service
  15. * Author : ChinthakaDi
  16. * Date : 11/8/2018 - 5:26 PM
  17. */
  18. @Getter
  19. @Setter
  20. @ToString
  21. @EqualsAndHashCode
  22. @Document(collection = "AppUser")
  23. public class AppUser {
  24.  
  25. @Id
  26. private String id;
  27.  
  28. @Indexed(unique = true)
  29. private String username;
  30.  
  31. private String password;
  32.  
  33. private String role;
  34.  
  35. private List<AppUserRole> appUserRoles;
  36.  
  37. public AppUser() {
  38. }
  39.  
  40. public AppUser(String id, String username, String password, String role) {
  41. this.id = id;
  42. this.username = username;
  43. this.password = password;
  44. this.role = role;
  45. }
  46. }
Add Comment
Please, Sign In to add comment