mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-27 14:27:15 +00:00
Added new result containing sorted set data
This commit is contained in:
1 parent
3a72b6d159
commit
363bf5f5d7
1 file changed
+26
+26
@@ -0,0 +1,26 @@
|
||||
package com.sap.sailing.gwt.ui.shared.dispatch;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.Set;
|
||||
import java.util.TreeSet;
|
||||
|
||||
public class SortedSetResult<T extends DTO> implements DTO, Result {
|
||||
private TreeSet<T> values = new TreeSet<>();
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
private SortedSetResult() {
|
||||
}
|
||||
|
||||
public SortedSetResult(Collection<T> values) {
|
||||
super();
|
||||
this.values.addAll(values);
|
||||
}
|
||||
|
||||
public Set<T> getValues() {
|
||||
return values;
|
||||
}
|
||||
|
||||
public boolean isEmpty() {
|
||||
return values.isEmpty();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user