Example #1
0
 public void Dispose()
 {
     if (objBGPlayer != null)
     {
         objBGPlayer.OnShotBoxStatus           -= objPlayer1_OnShotBoxStatus;
         objBGPlayer.OnShotBoxControllerStatus -= objPlayer1_OnShotBoxStatus;
         objBGPlayer.Dispose();
         objBGPlayer = null;
     }
     if (objScorePlayer != null)
     {
         objScorePlayer.OnShotBoxStatus           -= objPlayer1_OnShotBoxStatus;
         objScorePlayer.OnShotBoxControllerStatus -= objPlayer1_OnShotBoxStatus;
         objScorePlayer.Dispose();
         objScorePlayer = null;
     }
     if (AppLink != null)
     {
         AppLink.Dispose();
         AppLink = null;
     }
     if (FileHandler != null)
     {
         FileHandler.Dispose();
         FileHandler = null;
     }
 }
Example #2
0
        private void InitializeWasp()
        {
            _CommonPath = Environment.GetEnvironmentVariable("Wasp3.5");

            var configfile = Path.Combine(_CommonPath, "CommonConfig.config");

            XDocument xdoc = XDocument.Load(configfile);
            var url = from lv1 in xdoc.Descendants("add")
                      where lv1.Attribute("key").Value == "LOCALMANAGERURL"
                      select lv1.Attribute("value").Value;
            _objRemoteHelper = new CRemoteHelper(url.ElementAt(0));
            ConnectionInfo info = _objRemoteHelper.CheckConnection();
            if (info.status == Status.Connected)
            {
                objWaspFileHandler = new CWaspFileHandler();
                objWaspFileHandler.Initialize(CRemoteHelper.GetDisconnectedUrl("TemplateManager"));
            }
        }
Example #3
0
        private void InitializeWasp()
        {
            _CommonPath = Environment.GetEnvironmentVariable("Wasp3.5");

            var configfile = Path.Combine(_CommonPath, "CommonConfig.config");

            XDocument xdoc = XDocument.Load(configfile);
            var       url  = from lv1 in xdoc.Descendants("add")
                             where lv1.Attribute("key").Value == "LOCALMANAGERURL"
                             select lv1.Attribute("value").Value;

            _objRemoteHelper = new CRemoteHelper(url.ElementAt(0));
            ConnectionStatus info = _objRemoteHelper.Connect();

            _mObjUdtHandler    = new CUDTManagerHelper(CRemoteHelper.GetDisconnectedUrl("UDTManager"));
            objWaspFileHandler = new CWaspFileHandler();
            objWaspFileHandler.Initialize(CRemoteHelper.GetDisconnectedUrl("TemplateManager"));
        }
Example #4
0
 /// <summary>
 /// Create wasp kc connection and get template manager object
 /// </summary>
 private void InitializeWasp()
 {
     try
     {
         m_sCommonPath = Environment.GetEnvironmentVariable("Wasp3.5");
         System.Diagnostics.Debug.WriteLine("InitializeWasp Commonpath:" + m_sCommonPath);
         var configfile = Path.Combine(m_sCommonPath, "CommonConfig.config");
         System.Diagnostics.Debug.WriteLine("InitializeWasp configfile:" + configfile);
         XDocument xdoc = XDocument.Load(configfile);
         var url = from lv1 in xdoc.Descendants("add")
                   where lv1.Attribute("key").Value == "LOCALMANAGERURL"
                   select lv1.Attribute("value").Value;
         System.Diagnostics.Debug.WriteLine("InitializeWasp Url:" + url.ElementAt(0));
         m_objRemoteHelper = new CRemoteHelper(url.ElementAt(0));
         ConnectionInfo info = m_objRemoteHelper.CheckConnection();
         if (info.status == Status.Connected)
         {
             ServiceUrl templatemgrserviceurl = CRemoteHelper.GetDisconnectedUrl("TemplateManager");
             m_objWaspFileHandler = new CWaspFileHandler();
             m_objWaspFileHandler.Initialize(templatemgrserviceurl);
             LoadTemplates();
         }
     }
     catch (Exception ex)
     {
         LogWriter.WriteLog(ex);
     }
 }
Example #5
0
 /// <summary>
 /// Initializing the components
 /// </summary>
 private void Init()
 {
     try
     {
         m_serverurl = string.Format(m_surlformat, ConfigurationManager.AppSettings["stingserverip"], ConfigurationManager.AppSettings["stingserverport"]);
         m_objWaspFileHandler = new CWaspFileHandler();
         m_objsceneHandler = new SceneHandler();
         objPlayergetter = new PlayerGetter();
         SetUI();
         InitializeWasp();
         InitilizeMatchScheduleUdt();
         InitializeCombos();
         FillMatchDetails();
         Fillgrid();
         m_objsceneHandler.FileHandler = m_objWaspFileHandler;
         m_objsceneHandler.Initialize();
         m_objsceneHandler.Hometeamscore = lblHomeScore.Text;
         m_objsceneHandler.Awayteamscore = lblAwayScore.Text;
         m_objsceneHandler.Hometeamshortname = hometeamshortname;
         m_objsceneHandler.Awayteamshortname = awayteamshortname;
         m_objsceneHandler.SetMatchUdt();
     }
     catch (Exception ex)
     {
         LogWriter.WriteLog(ex);
     }
 }