Exemplo n.º 1
0
 static bool CheckForMeasIDMatch(INCCDB.IndexedResults ir)
 {
     if (sel.Start <= ir.DateTime && sel.End >= ir.DateTime)
     {
         return (string.Compare(sel.InspectionNumber, "All", true) == 0) ||
                (string.Compare(sel.InspectionNumber, ir.Campaign, true) == 0);
     }
     return false;
 }
Exemplo n.º 2
0
 public void LoadPersistenceConfig(DBConfig mynewdb)
 {
     pest = new Persistence(Logger(LMLoggers.AppSection.DB), mynewdb);
     DB = new INCCDB();
     DB.Populate(pest);
     lmdb = new ListModeDB.LMDB();
     lmdb.Populate(pest);
     appctx = ListModeDB.LMDB.AppContext;
 }
Exemplo n.º 3
0
 public bool LoadPersistenceConfig(DBConfig mynewdb)
 {
     pest = new Persistence(Logger(LMLoggers.AppSection.DB), mynewdb);
     DB = new INCCDB();
     lmdb = new LMDB();
     bool there = false;
     try
     {
         there = pest.IsItThere;
         if (!there)
         {
             Console.WriteLine("Database using " + mynewdb.MyDBConnectionString + " unavailable");
             Console.WriteLine(pest.IsItThereStr);
         }
     }
     catch (Exception ex)
     {
         Console.WriteLine("Database unavailable " + ex.Message);
         if (!string.IsNullOrEmpty(pest.IsItThereStr))
             Console.WriteLine(pest.IsItThereStr);
     }
     if (there)
         appctx = LMDB.AppContext;
     return there;
 }
Exemplo n.º 4
0
 List<string> GenMeasStr(INCCDB.IndexedResults ir)
 {
     List<string> _ls = new List<string>();
     string l = ir.Rid.ToString() + " cycles";
     //if (!string.IsNullOrEmpty(ir.Campaign))
     //    l = l + ", campaign: " + ir.Campaign;
     _ls.Add(l);
     return _ls;
 }