pro.lukasgorny.enums.PUBGSeason Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jpubg-android Show documentation
Show all versions of jpubg-android Show documentation
Simple API wrapper written in Java for retriving statistics from http://pubgtracker.com API.
This is Android version without Java 8 features to provide full compatibility with Android.
package pro.lukasgorny.enums;
import java.util.HashMap;
import java.util.Map;
/**
* Created by Łukasz "Husar" Górny on 2017-07-11.
*/
public enum PUBGSeason {
PRE1_2017("2017-pre1"),
PRE2_2017("2017-pre2"),
PRE3_2017("2017-pre3"),
PRE4_2017("2017-pre4");
PUBGSeason(String seasonName) {
this.seasonName = seasonName;
}
private String seasonName;
private static final Map map;
public String getSeasonName() {
return seasonName;
}
static {
map = new HashMap<>();
for (PUBGSeason season : PUBGSeason.values()) {
map.put(season.getSeasonName(), season);
}
}
public static PUBGSeason findByKey(String toFind) {
return map.get(toFind);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy