You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
78 lines
1.5 KiB
78 lines
1.5 KiB
package data;
|
|
|
|
public enum Collocability {
|
|
DICE("Dice"),
|
|
TSCORE("t-score"),
|
|
MI("MI"),
|
|
MI3("MI3"),
|
|
LOGDICE("logDice"),
|
|
SIMPLELL("simple LL");
|
|
|
|
private final String name;
|
|
|
|
Collocability(String name) {
|
|
this.name = name;
|
|
}
|
|
|
|
public String toString() {
|
|
return this.name;
|
|
}
|
|
|
|
public static Collocability factory(String cf) {
|
|
if (cf != null) {
|
|
if (DICE.toString().equals(cf)) {
|
|
return DICE;
|
|
} else if (TSCORE.toString().equals(cf)) {
|
|
return TSCORE;
|
|
} else if (MI.toString().equals(cf)) {
|
|
return MI;
|
|
} else if (MI3.toString().equals(cf)) {
|
|
return MI3;
|
|
} else if (LOGDICE.toString().equals(cf)) {
|
|
return LOGDICE;
|
|
} else if (SIMPLELL.toString().equals(cf)) {
|
|
return SIMPLELL;
|
|
}
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public String toMetadataString() {
|
|
switch(this){
|
|
case DICE:
|
|
return "Dice";
|
|
case TSCORE:
|
|
return "t-score";
|
|
case MI:
|
|
return "MI";
|
|
case MI3:
|
|
return "MI3";
|
|
case LOGDICE:
|
|
return "logDice";
|
|
case SIMPLELL:
|
|
return "simple LL";
|
|
default:
|
|
return null;
|
|
}
|
|
}
|
|
|
|
public String toHeaderString() {
|
|
switch(this){
|
|
case DICE:
|
|
return "Dice";
|
|
case TSCORE:
|
|
return "t-score";
|
|
case MI:
|
|
return "MI";
|
|
case MI3:
|
|
return "MI3";
|
|
case LOGDICE:
|
|
return "logDice";
|
|
case SIMPLELL:
|
|
return "simple LL";
|
|
default:
|
|
return null;
|
|
}
|
|
}
|
|
}
|