package data; public enum Collocability { DICE("Dice"); 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; } } return null; } public String toMetadataString() { switch(this){ case DICE: return "Kolokabilnost - Dice:"; default: return null; } } public String toHeaderString() { switch(this){ case DICE: return "Kolokabilnost - Dice"; default: return null; } } // public String toPercentString() { // switch(this){ // case DICE: // return "Delež glede na vse različnice"; // default: // return null; // } // } }