类 GtApiConfiguration


  • public class GtApiConfiguration
    extends Object
    应用相关配置信息 create by getui on 2020/6/4
    作者:
    getui
    • 字段详细资料

      • ANALYSE_STABLE_DOMAIN_SWITCH_KEY

        public static final String ANALYSE_STABLE_DOMAIN_SWITCH_KEY
        是否开启最稳定域名检测,默认开启
        另请参阅:
        常量字段值
      • GT_TOP_LEVEL_DOMAIN_LIST_KEY

        public static final String GT_TOP_LEVEL_DOMAIN_LIST_KEY
        个推顶级域名列表,英文逗号分割
        另请参阅:
        常量字段值
      • CHECK_HEALTH_DATA_SWITCH_KEY

        public static final String CHECK_HEALTH_DATA_SWITCH_KEY
        如果遇到域名请求地址不断变化或需要排查网络耗时等问题,可以开启此接口(方法)功能后,联系个推技术支持 健康度检查动态开关,true表示开启,否则关闭,不设置则取 ANALYSE_STABLE_DOMAIN_SWITCH_KEY
        另请参阅:
        常量字段值
    • 构造器详细资料

      • GtApiConfiguration

        public GtApiConfiguration()
    • 方法详细资料

      • setDomain

        public void setDomain​(String domain)
        参数:
        domain - 接口调用前缀, 可不含appId
      • check

        public void check()
      • isTrustSSL

        public boolean isTrustSSL()
      • setTrustSSL

        public void setTrustSSL​(boolean trustSSL)
      • getAppId

        public String getAppId()
      • setAppId

        public void setAppId​(String appId)
      • getAppKey

        public String getAppKey()
      • setAppKey

        public void setAppKey​(String appKey)
      • getMasterSecret

        public String getMasterSecret()
      • setMasterSecret

        public void setMasterSecret​(String masterSecret)
      • getDomain

        public String getDomain()
      • getGtTopLevelDomainList

        public Set<String> getGtTopLevelDomainList()
      • setGtTopLevelDomainList

        public void setGtTopLevelDomainList​(String list)
      • isOpenAnalyseStableDomainSwitch

        public boolean isOpenAnalyseStableDomainSwitch()
      • setOpenAnalyseStableDomainSwitch

        public void setOpenAnalyseStableDomainSwitch​(boolean openAnalyseStableDomainSwitch)
      • getAnalyseStableDomainInterval

        public long getAnalyseStableDomainInterval()
      • setAnalyseStableDomainInterval

        public void setAnalyseStableDomainInterval​(long analyseStableDomainInterval)
      • isOpenCheckHealthDataSwitch

        public boolean isOpenCheckHealthDataSwitch()
      • setOpenCheckHealthDataSwitch

        public void setOpenCheckHealthDataSwitch​(boolean openCheckHealthDataSwitch)
      • getCheckHealthInterval

        public long getCheckHealthInterval()
      • setCheckHealthInterval

        public void setCheckHealthInterval​(long checkHealthInterval)
      • getSoTimeout

        public int getSoTimeout()
      • setSoTimeout

        public void setSoTimeout​(int soTimeout)
      • getConnectTimeout

        public int getConnectTimeout()
      • setConnectTimeout

        public void setConnectTimeout​(int connectTimeout)
      • getConnectionRequestTimeout

        public int getConnectionRequestTimeout()
      • setConnectionRequestTimeout

        public void setConnectionRequestTimeout​(int connectionRequestTimeout)
      • getMaxHttpTryTime

        public int getMaxHttpTryTime()
      • setMaxHttpTryTime

        public void setMaxHttpTryTime​(int maxHttpTryTime)
      • getKeepAliveSeconds

        public long getKeepAliveSeconds()
      • setKeepAliveSeconds

        public void setKeepAliveSeconds​(long keepAliveSeconds)
      • getKeepAliveMinutes

        @Deprecated
        public long getKeepAliveMinutes()
        已过时。
        replaced by getKeepAliveSeconds(). will be removed in the next version
        返回:
      • setKeepAliveMinutes

        @Deprecated
        public void setKeepAliveMinutes​(long keepAliveMinutes)
        已过时。
        replaced by setKeepAliveSeconds(). will be removed in the next version
        参数:
        keepAliveMinutes -
      • hashCode

        public int hashCode()
        覆盖:
        hashCode 在类中 Object
      • keyOfCache

        public String keyOfCache()
        生成缓存的key
        返回:
        缓存key
      • prefixOfKey

        public String prefixOfKey()
        缓存key的前缀
        返回:
        keyOfCache()的前缀,用于修改masterSecret