From 032eddac4b4627f855905e8e846b0388483e3979 Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期三, 11 九月 2019 11:58:50 +0800 Subject: [PATCH] 客户端参数/系统参数增加版本区分 --- fanli/src/main/java/com/yeshi/fanli/util/VersionUtil.java | 67 +++++++++++++++++++++++++++++++++ 1 files changed, 67 insertions(+), 0 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/util/VersionUtil.java b/fanli/src/main/java/com/yeshi/fanli/util/VersionUtil.java index e234b2f..0f16d8a 100644 --- a/fanli/src/main/java/com/yeshi/fanli/util/VersionUtil.java +++ b/fanli/src/main/java/com/yeshi/fanli/util/VersionUtil.java @@ -10,4 +10,71 @@ return false; } + public static boolean greaterThan_1_5_50(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 42)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 52))) + return true; + else + return false; + } + + public static boolean greaterThan_1_5_60(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 43)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 54))) + return true; + else + return false; + } + + + public static boolean greaterThan_1_5_70(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 45)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 56))) + return true; + else + return false; + } + + public static boolean greaterThan_1_6_0(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 46)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 58))) + return true; + else + return false; + } + + public static boolean greaterThan_1_6_5(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 47)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 65))) + return true; + else + return false; + } + + public static boolean greaterThan_2_0_0(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 48)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 66))) + return true; + else + return false; + } + + + public static boolean greaterThan_2_0(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 48)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) >= 66))) + return true; + else + return false; + } + + + public static boolean smallerThan_1_5_1(String platform, String versionCode) { + if ((("android".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) < 36)) + || (("ios".equalsIgnoreCase(platform) && Integer.parseInt(versionCode) < 44))) + return true; + else + return false; + } + } -- Gitblit v1.8.0