75 lines
1.4 KiB
Java
75 lines
1.4 KiB
Java
package eu.eudat.models.dashboard.recent;
|
|
|
|
import java.util.Date;
|
|
|
|
/**
|
|
* Created by ikalyvas on 3/14/2018.
|
|
*/
|
|
public class RecentActivityData {
|
|
|
|
public enum RecentActivityType {
|
|
PROJECT(0), DATASET(1), DMP(2);
|
|
|
|
private Integer value;
|
|
|
|
public Integer getValue() {
|
|
return value;
|
|
}
|
|
|
|
private RecentActivityType(int value) {
|
|
this.value = value;
|
|
}
|
|
|
|
public static RecentActivityType fromValue(Integer value) {
|
|
switch (value) {
|
|
case 0:
|
|
return PROJECT;
|
|
case 1:
|
|
return DATASET;
|
|
case 2:
|
|
return DMP;
|
|
default:
|
|
throw new RuntimeException("Unsupported Recent Activity Status");
|
|
}
|
|
}
|
|
}
|
|
|
|
private String label;
|
|
private String id;
|
|
private Date timestamp;
|
|
private Integer type;
|
|
|
|
public String getId() {
|
|
return id;
|
|
}
|
|
|
|
public void setId(String id) {
|
|
this.id = id;
|
|
}
|
|
|
|
public Integer getType() {
|
|
return type;
|
|
}
|
|
|
|
public void setType(Integer type) {
|
|
this.type = type;
|
|
}
|
|
|
|
public Date getTimestamp() {
|
|
return timestamp;
|
|
}
|
|
|
|
public void setTimestamp(Date timestamp) {
|
|
this.timestamp = timestamp;
|
|
}
|
|
|
|
public String getLabel() {
|
|
return label;
|
|
}
|
|
|
|
public void setLabel(String label) {
|
|
this.label = label;
|
|
}
|
|
|
|
}
|