Commit e0e40983 authored by Killian LUCAS's avatar Killian LUCAS
Browse files

push user

parent 3df2a92e
package fr.univnantes.alma.data.item;
import javax.persistence.*;
@Entity
@Table(name="users")
public class User {
@Id
@GeneratedValue(strategy= GenerationType.AUTO)
private Long id;
private String mail;
private String passwordHash;
private String pseudo;
......@@ -9,11 +16,20 @@ public class User {
protected User(){}
public User(String mail, String password, String pseudo){
this.mail = this.mail;
this.mail = mail;
this.passwordHash = hash(password);
this.pseudo = pseudo;
}
@Override
public String toString() {
return String.format(
"Customer[id=%d, mail='%s', password='%s',pseudo='%s']",
id, mail, passwordHash,pseudo);
}
public Long getId(){
return id;
}
public String getMail() {
return mail;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment