Skip to content
Snippets Groups Projects
Commit 567598ea authored by Paul-Christian Volkmer's avatar Paul-Christian Volkmer
Browse files

Add property to LoggedIn entity

This indicates conflicts in CouchDB that should be handled by
application. Those conflicts might occure, if a single user is logged in
on two different devices at the same time.
parent aa28f9de
Branches
Tags
No related merge requests found
......@@ -31,6 +31,7 @@ public class LoggedIn {
private String sessionId;
private long timestamp;
private List<VisitedSession> visitedSessions = new ArrayList<VisitedSession>();
private List<String> _conflicts;
public LoggedIn() {
this.type = "logged_in";
......@@ -111,6 +112,18 @@ public class LoggedIn {
public void setVisitedSessions(List<VisitedSession> visitedSessions) {
this.visitedSessions = visitedSessions;
}
public List<String> get_conflicts() {
return _conflicts;
}
public void set_conflicts(List<String> _conflicts) {
this._conflicts = _conflicts;
}
public boolean hasConflicts() {
return ! (_conflicts == null && _conflicts.isEmpty());
}
@Override
public String toString() {
......
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