generic ranks
This commit is contained in:
parent
5fd15f1e51
commit
b092be40c3
|
|
@ -0,0 +1,33 @@
|
|||
package org.r0r5chach;
|
||||
|
||||
import java.util.Locale;
|
||||
|
||||
/**
|
||||
* All levels a ValorantPlayer can be
|
||||
* @author r0r5chach
|
||||
*/
|
||||
public enum Rank {
|
||||
/**
|
||||
* First Level
|
||||
*/
|
||||
BRONZE,
|
||||
/**
|
||||
* Second Level
|
||||
*/
|
||||
SILVER,
|
||||
/**
|
||||
* Third Level
|
||||
*/
|
||||
GOLD,
|
||||
/**
|
||||
* Four Level
|
||||
*/
|
||||
PLATINUM;
|
||||
/**
|
||||
* Get the name of a level
|
||||
* @return a formatted string containing the level name
|
||||
*/
|
||||
public String getRank() {
|
||||
return this.name().charAt(0) + this.name().substring(1).toLowerCase(Locale.ROOT); //Capitalizes the first letter and makes sure the other letters are lowercase
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue