Files
Athou_commafeed/src/main/java/com/commafeed/frontend/model/UserModel.java

85 lines
1.6 KiB
Java
Raw Normal View History

2013-03-29 16:05:29 +01:00
package com.commafeed.frontend.model;
import java.io.Serializable;
2013-04-15 14:47:37 +02:00
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;
2013-04-17 13:26:14 +02:00
import com.wordnik.swagger.annotations.ApiClass;
import com.wordnik.swagger.annotations.ApiProperty;
2013-03-29 16:05:29 +01:00
@SuppressWarnings("serial")
2013-04-15 14:47:37 +02:00
@XmlRootElement
@XmlAccessorType(XmlAccessType.FIELD)
2013-04-17 13:26:14 +02:00
@ApiClass("User information")
2013-03-29 16:05:29 +01:00
public class UserModel implements Serializable {
2013-04-17 13:26:14 +02:00
@ApiProperty(value = "user id", required = true)
2013-03-30 09:22:49 +01:00
private Long id;
2013-04-17 13:26:14 +02:00
@ApiProperty(value = "user name", required = true)
2013-03-29 16:05:29 +01:00
private String name;
2013-04-17 13:26:14 +02:00
@ApiProperty("user email, if any")
2013-04-13 12:19:59 +02:00
private String email;
2013-04-17 13:26:14 +02:00
@ApiProperty(value = "user password, never returned by the api")
2013-03-30 09:22:49 +01:00
private String password;
2013-04-17 13:26:14 +02:00
@ApiProperty(value = "account status")
2013-03-29 16:05:29 +01:00
private boolean enabled;
2013-04-17 13:26:14 +02:00
@ApiProperty(value = "user is admin")
2013-03-29 22:18:27 +01:00
private boolean admin;
2013-03-29 16:05:29 +01:00
2013-03-30 09:22:49 +01:00
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
2013-03-29 16:05:29 +01:00
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
2013-03-29 22:18:27 +01:00
public boolean isAdmin() {
return admin;
2013-03-29 16:05:29 +01:00
}
2013-03-29 22:18:27 +01:00
public void setAdmin(boolean admin) {
this.admin = admin;
2013-03-29 16:05:29 +01:00
}
public boolean isEnabled() {
return enabled;
}
public void setEnabled(boolean enabled) {
this.enabled = enabled;
}
2013-03-30 09:22:49 +01:00
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
2013-04-13 12:19:59 +02:00
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
2013-03-29 16:05:29 +01:00
}