Ejemplo n.º 1
0
        public void TimerProc(object sender, EventArgs e)
        {
            try
            {
                string uri = _CoreInterface.GetRuntimeVariable(RuntimeVariableNames.SpreadUri, null);
                if (_RemoteServiceUri != uri)
                {
                    _RemoteServiceUri = uri;
                }

                ISpreadService kuaFuService = GetKuaFuService();
                if (null != kuaFuService)
                {
                    if (_ClientInfo.ClientId > 0)
                    {
                        //同步数据
                        AsyncDataItem[] items = kuaFuService.GetClientCacheItems(_ClientInfo.ServerId);
                        if (null != items && items.Length > 0)
                        {
                            ExecuteEventCallBackAsync(items);
                        }
                    }
                }

                CheckSpreadData();
            }
            catch (System.Exception ex)
            {
                ResetKuaFuService();
            }
        }
Ejemplo n.º 2
0
 public void TimerProc(object sender, EventArgs e)
 {
     try
     {
         string uri = this._CoreInterface.GetRuntimeVariable("SpreadUri", null);
         if (this._RemoteServiceUri != uri)
         {
             this._RemoteServiceUri = uri;
         }
         ISpreadService kuaFuService = this.GetKuaFuService(false);
         if (null != kuaFuService)
         {
             if (this._ClientInfo.ClientId > 0)
             {
                 AsyncDataItem[] items = kuaFuService.GetClientCacheItems(this._ClientInfo.ServerId);
                 if (items != null && items.Length > 0)
                 {
                     this.ExecuteEventCallBackAsync(items);
                 }
             }
         }
         this.CheckSpreadData();
     }
     catch (Exception ex)
     {
         this.ResetKuaFuService();
     }
 }