com.uwetrottmann.trakt5.enums.ListPrivacy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of trakt-java Show documentation
Show all versions of trakt-java Show documentation
trakt-java is a retrofit2 based wrapper around the trakt API v2.
package com.uwetrottmann.trakt5.enums;
import java.util.HashMap;
import java.util.Map;
public enum ListPrivacy implements TraktEnum {
PRIVATE("private"),
FRIENDS("friends"),
PUBLIC("public");
public final String value;
private ListPrivacy(String value) {
this.value = value;
}
private static final Map STRING_MAPPING = new HashMap<>();
static {
for (ListPrivacy via : ListPrivacy.values()) {
STRING_MAPPING.put(via.toString(), via);
}
}
public static ListPrivacy fromValue(String value) {
return STRING_MAPPING.get(value);
}
@Override
public String toString() {
return value;
}
}