1
|
package eu.dnetlib.rmi.data;
|
2
|
|
3
|
import java.util.Arrays;
|
4
|
import java.util.HashSet;
|
5
|
import java.util.List;
|
6
|
import java.util.Set;
|
7
|
import java.util.stream.Collectors;
|
8
|
|
9
|
/**
|
10
|
* Enum of supported hadoop job types.
|
11
|
*
|
12
|
* @author claudio
|
13
|
*/
|
14
|
public enum DedupJobType {
|
15
|
|
16
|
/**
|
17
|
* The mapreduce.
|
18
|
*/
|
19
|
DUPLICATE_SCAN,
|
20
|
|
21
|
/**
|
22
|
* The admin.
|
23
|
*/
|
24
|
CLOSE_SIMILARITY_MESH;
|
25
|
|
26
|
public static Set<String> asStringSet() {
|
27
|
return new HashSet<>(asStringList());
|
28
|
}
|
29
|
|
30
|
public static List<String> asStringList() {
|
31
|
return asList().stream().map(it -> it.toString()).collect(Collectors.toList());
|
32
|
|
33
|
}
|
34
|
|
35
|
public static List<DedupJobType> asList() {
|
36
|
return Arrays.asList(DedupJobType.values());
|
37
|
}
|
38
|
}
|