Пример #1
0
 private IPtoDNS GetOrCreateIP(string ipaddress)
 {
     loggingDataContext db = new loggingDataContext();
     IPtoDNS ipdetails = db.IPtoDNS.Where(x => x.ipaddress.Equals(ipaddress.Trim())).FirstOrDefault();
     if (ipdetails == null || ipdetails.ID == 0) {
         ipdetails = new IPtoDNS {
             ipaddress = ipaddress.Trim(),
             dateChecked = DateTime.Now
         };
         db.IPtoDNS.InsertOnSubmit(ipdetails);
         db.SubmitChanges();
         ipdetails.LookupAsync();
     }
     return ipdetails;
 }
Пример #2
0
 partial void DeleteIPtoDNS(IPtoDNS instance);
Пример #3
0
 partial void UpdateIPtoDNS(IPtoDNS instance);
Пример #4
0
 partial void InsertIPtoDNS(IPtoDNS instance);