/// <summary> /// 防止没有主动调用Close /// </summary> public void Dispose() { if (infoCodeList != null && infoCodeList.Count > 0) { RemoteInfoHelper.RevokeInfo(this); } }
/// <summary> /// 构造函数 /// </summary> /// <param name="codes">接受的信息列表</param> /// <param name="callback">回调函数</param> public RemoteInfoReceiver(List <String> codes, OnCallbackInfo callback) { infoCodeList = codes; callbackInfo = callback; // 注册信息码 if (infoCodeList.Count > 0) { RemoteInfoHelper.RegisterInfo(this, infoCodeList); } }