package dev.openshift.tapestry.angular.data.user;

import java.io.Serializable;
import java.util.Date;

public class User implements Serializable
{
	private static final long serialVersionUID = 1L;
	private int id;
	private String uri;
	private String firstName;
	private String lastName;
	private Date lastModified;
    private String email;
    private String login;
    private String password;
    private String[] roles;

    public User() {}

    public Date getLastModified() {
		return lastModified;
	}
	public void setLastModified(Date lastModified) {
		this.lastModified = lastModified;
	}
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public String getFirstName() {
		return firstName;
	}
	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}
	public String getLastName() {
		return lastName;
	}
	public void setLastName(String lastName) {
		this.lastName = lastName;
	}
	public String getUri() {
		return uri;
	}
	public void setUri(String uri) {
		this.uri = uri;
	}
    public String getEmail() {
        return email;
    }
    public void setEmail(String email) {
        this.email = email;
    }
    public String getLogin() {
        return login;
    }
    public void setLogin(String login) {
        this.login = login;
    }
    public String getPassword() {
        return password;
    }
    public void setPassword(String password) {
        this.password = password;
    }
    public String[] getRoles() {
        return roles;
    }
    public void setRoles(String[] roles) {
        this.roles = roles;
    }
}

@@ -46,16 +46,98 @@
 ser;%0D%0A%0D%0A
+import org.apache.tapestry5.beaneditor.NonVisual;%0D%0A%0D%0Aimport javax.persistence.*;%0D%0A
 import j
@@ -182,16 +182,49 @@
 .Date;%0D%0A
+import java.util.List;%0D%0A%0D%0A@Entity
 %0D%0Apublic
@@ -314,17 +314,36 @@
  = 1L;%0D%0A
-%09
+    @Transient%0D%0A    
 private 
@@ -480,24 +480,33 @@
 ing email;%0D%0A
+    @Id%0D%0A
     private 
@@ -546,24 +546,155 @@
  password;%0D%0A
+    @ElementCollection%0D%0A    @CollectionTable(name=%22Roles%22, joinColumns=@JoinColumn(name=%22user_login%22))%0D%0A    @Column(name=%22roles%22)%0D%0A
     private 
@@ -693,24 +693,28 @@
 private 
+List%3C
 String
-%5B%5D
+%3E
  roles;%0D
@@ -1816,24 +1816,28 @@
  public 
+List%3C
 String
-%5B%5D
+%3E
  getRole
@@ -1902,16 +1902,20 @@
 les(
+List%3C
 String
-%5B%5D
+%3E
  rol

add annotations