Beispiel #1
0
 public void SelectConstructorTest8()
 {
     Column[] selectedItems = null; // TODO: Initialize to an appropriate value
     From.From from = null; // TODO: Initialize to an appropriate value
     Where.Where where = null; // TODO: Initialize to an appropriate value
     Select.Select target = new Select.Select(selectedItems, from, where);
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
Beispiel #2
0
 public void SelectConstructorTest9()
 {
     List<Expression> selectedItems = null; // TODO: Initialize to an appropriate value
     From.From from = null; // TODO: Initialize to an appropriate value
     Where.Where where = null; // TODO: Initialize to an appropriate value
     GroupBy.GroupBy groupBy = null; // TODO: Initialize to an appropriate value
     OrderBy.OrderBy orderBy = null; // TODO: Initialize to an appropriate value
     Select.Select target = new Select.Select(selectedItems, from, where, groupBy, orderBy);
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
Beispiel #3
0
 public void SelectConstructorTest7()
 {
     Top top = null; // TODO: Initialize to an appropriate value
     List<Expression> selectedItems = null; // TODO: Initialize to an appropriate value
     Where.Where where = null; // TODO: Initialize to an appropriate value
     Select.Select target = new Select.Select(top, selectedItems, where);
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
Beispiel #4
0
 public void SelectConstructorTest3()
 {
     Top top = null; // TODO: Initialize to an appropriate value
     List<Expression> selectList = null; // TODO: Initialize to an appropriate value
     From.From from = null; // TODO: Initialize to an appropriate value
     Where.Where where = null; // TODO: Initialize to an appropriate value
     OrderBy.OrderBy orderBy = null; // TODO: Initialize to an appropriate value
     Select.Select target = new Select.Select(top, selectList, from, where, orderBy);
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
Beispiel #5
0
 public void SelectConstructorTest22()
 {
     Top top = null; // TODO: Initialize to an appropriate value
     Expression selectItem = null; // TODO: Initialize to an appropriate value
     From.From from = null; // TODO: Initialize to an appropriate value
     Where.Where where = null; // TODO: Initialize to an appropriate value
     GroupBy.GroupBy groupBy = null; // TODO: Initialize to an appropriate value
     Select.Select target = new Select.Select(top, selectItem, from, where, groupBy);
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
Beispiel #6
0
 public void SelectConstructorTest19()
 {
     Top top = null; // TODO: Initialize to an appropriate value
     OrderBy.OrderBy orderBy = null; // TODO: Initialize to an appropriate value
     Select.Select target = new Select.Select(top, orderBy);
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
Beispiel #7
0
 /// <summary>
 /// Процесс загрузки данных с PrintServer инспекции
 /// </summary>
 public List <SynchronizationPrintServer> SynchronizationPrintServerStart()
 {
     try
     {
         var selectProcess = new Select.Select();
         var process       = selectProcess.SelectProcess(IndexProcess);
         if (process.IsComplete != null && (bool)process.IsComplete)
         {
             var addObjectDb = new AddObjectDb.AddObjectDb();
             addObjectDb.IsProcessComplete(IndexProcess, false);
             var task = Task.Factory.StartNew(() =>
             {
                 try
                 {
                     var ping                 = new Ping();
                     var printServer          = new PrintServer(PrintServer);
                     var selectModel          = new Select.Select();
                     var allModel             = selectModel.AllFullModel();
                     var allSerialNumberModel = selectModel.AllSerNumber();
                     var prQueue              = printServer.GetPrintQueues();
                     var listPrinters         = (from printer in prQueue
                                                 select new SynchronizationPrintServer()
                     {
                         DescriptionPrinter = printer.Comment,
                         NamePrintServer = printer.Name,
                         IpPrintServer = UnderTheNetwork + Regex.Match(printer.QueuePort.Name, @"(\d+)(?!.*\d)").Value,
                         HasToner = printer.HasToner,
                         IsTonerLow = printer.IsTonerLow
                     }
                                                 ).ToList();
                     foreach (var model in allModel)
                     {
                         var findModelName = Regex.Match(model.NameModel, @"(\d+)(?!.*\d)").Value;
                         if (!string.IsNullOrWhiteSpace(findModelName))
                         {
                             foreach (var printer in listPrinters)
                             {
                                 if (printer.DescriptionPrinter.Contains(findModelName))
                                 {
                                     printer.FullUrl     = string.Format(string.IsNullOrWhiteSpace(model.UrlModel) ? "http://{0}" : model.UrlModel, printer.IpPrintServer);
                                     PingReply pingReply = ping.Send(printer.IpPrintServer);
                                     if (pingReply != null && pingReply.Status == IPStatus.Success)
                                     {
                                         if (findModelName == "7030")
                                         {
                                             SoapClientPrinter(allSerialNumberModel, printer);
                                             Dispose();
                                         }
                                         else
                                         {
                                             ClientSendWebForm(allSerialNumberModel, printer);
                                             Dispose();
                                         }
                                     }
                                     else
                                     {
                                         printer.IsErrorInfo = "Удаленный IP не пингуется!";
                                         printer.StatusFindPrintServerAndSynchronization = 4;
                                     }
                                 }
                             }
                         }
                     }
                     addObjectDb.AddListSynchronizationPrintServer(ref listPrinters);
                     selectModel.Dispose();
                     return(listPrinters);
                 }
                 catch (Exception e)
                 {
                     Loggers.Log4NetLogger.Error(e);
                 }
                 return(null);
             }, TaskCreationOptions.LongRunning);
             task.ConfigureAwait(true).GetAwaiter().OnCompleted(() =>
             {
                 addObjectDb.IsProcessComplete(IndexProcess, true);
                 addObjectDb.Dispose();
             });
             return(task.Result);
         }
         selectProcess.Dispose();
     }
     catch (Exception e)
     {
         Loggers.Log4NetLogger.Error(e);
     }
     return(null);
 }