/// <summary> /// 以配置的方式初始化Gatherer的上下文 /// </summary> public static void Setup() { if (hasInited) { return; } context = new GathererContext(); hasInited = true; }
/// <summary> /// 初始化Gatherer的上下文 /// </summary> /// <param name="appAccesstoken">应用的AccessToken</param> /// <param name="terminalId">默认使用终端的ID</param> public static void Setup(string appAccesstoken, int tId) { if (hasInited) { return; } if (String.IsNullOrWhiteSpace(appAccesstoken)) { throw new ArgumentException("应用的AccessToken不能为空"); } terminalId = tId; context = new GathererContext(); hasInited = true; }
/// <summary> /// 初始化Gatherer的上下文 /// </summary> /// <param name="appAccesstoken">应用的AccessToken</param> /// <param name="terminalId">默认使用终端的ID</param> public static void Setup(string appAccesstoken, int tId) { if (hasInited) return; if (String.IsNullOrWhiteSpace(appAccesstoken)) throw new ArgumentException("应用的AccessToken不能为空"); terminalId = tId; context = new GathererContext(); hasInited = true; }
/// <summary> /// 以配置的方式初始化Gatherer的上下文 /// </summary> public static void Setup() { if (hasInited) return; context = new GathererContext(); hasInited = true; }