Annotate all the things

This commit is contained in:
FalsePattern committed 2022-08-06 13:12:55 +02:00
1 parent 980e8a8776
commit da1ef6c8c7
63 files changed
+623 -369

No files matched your search

@@ -35,13 +35,16 @@ import static lombok.AccessLevel.PRIVATE;
@NoArgsConstructor(access = PRIVATE)
@StableAPI(since = "0.8.0")
public final class LangUtil {
@StableAPI.Expose
public static final String DEFAULT_LOCALE = "en_US";
private static final ThreadLocal<HashMap<String, String>> tempMap = ThreadLocal.withInitial(HashMap::new);
@StableAPI.Expose
public static void defaultLocalization(@NonNull Map<String, String> localeMap) {
localeMap.forEach(LangUtil::defaultLocalization);
}
@StableAPI.Expose
public static void defaultLocalization(@NonNull String key, @NonNull String value) {
if (!LanguageRegistry.instance().getStringLocalization(key, DEFAULT_LOCALE).isEmpty()) {
return;