package fr.univnantes.atal.web.trashnao.model;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

@PersistenceCapable
public class User {
    
    @PrimaryKey
    @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
    private String googleId;
    
    @Persistent
    private String refreshToken;

    public String getGoogleId() {
        return googleId;
    }

    public void setGoogleId(String googleId) {
        this.googleId = googleId;
    }

    public String getRefreshToken() {
        return refreshToken;
    }

    public void setRefreshToken(String refreshToken) {
        this.refreshToken = refreshToken;
    }
}

@@ -369,138 +369,19 @@
 ing 
-googleId;%0A    %0A    @Persistent%0A    private String refreshToken;%0A%0A    public String getGoogleId() %7B%0A        return googleId
+email
 ;%0A    
-%7D%0A
 %0A   
@@ -392,118 +392,23 @@
 lic 
-void setGoogleId(String googleId) %7B%0A        this.googleId = googleId;%0A    %7D%0A%0A    public String getRefreshToken
+String getEmail
 () %7B
@@ -423,28 +423,21 @@
  return 
-refreshToken
+email
 ;%0A    %7D%0A
@@ -460,84 +460,56 @@
  set
-RefreshToken(String refreshToken) %7B%0A        this.refreshToken = refreshToken
+Email(String email) %7B%0A        this.email = email
 ;%0A  

make email the key of users in the datastore and remove useless id