admin
2022-05-05 355fe96b2a4c7821256d9e8828d2cb9539904878
android/app/src/main/java/com/yeshi/makemoney/video/app/utils/AppConfigUtil.java
@@ -13,28 +13,20 @@
public class AppConfigUtil {
    /**
     * 浏览器外跳协议
     *
     * @param context
     * @param content
     */
    public static void saveBrowserJumpOutProtocolPrefix(Context context, String content) {
        saveConfig("jumpAppProtocolPrefix", content, context);
    public enum ConfigKey {
        kefu,
        unRegister,
        privacyComplain,
        helpLink
    }
    public static Set<String> getBrowserJumpOutProtocolPrefix(Context context) {
        try {
            String config = getConfig("jumpAppProtocolPrefix", context);
            if (!StringUtils.isEmpty(config)) {
                Type type = new TypeToken<Set<String>>() {
                }.getType();
                return new Gson().fromJson(config, type);
            }
        } catch (Exception e) {
            e.getMessage();
        }
        return new HashSet<>();
    public static void saveConfig(ConfigKey key, String value, Context context) {
        saveConfig(key.name(), value, context);
    }
    public static String getConfig(ConfigKey key, Context context) {
        return getConfig(key.name(), context);
    }