Example #1
0
 public void RegisterHistory(COMMU_TYPE type, string ip, string comment)
 {
     //list append
     history.Add(new Record(type, ip, comment));
     //database commit
     AddHistory(history.ElementAt(history.Count - 1));
 }
Example #2
0
 public Record(COMMU_TYPE Type, string ip, string mac, string comment, string time)
 {
     this.Type = Type;
     Ip        = ip;
     Mac       = mac;
     Comment   = comment;
     this.time = DateTime.ParseExact(time, "yyyy.MM.dd.HH.mm.ss.fff", CultureInfo.InvariantCulture);
 }
Example #3
0
 public Record(COMMU_TYPE Type, string ip, string comment)
 {
     this.Type = Type;
     Ip        = ip;
     Comment   = comment;
     Mac       = Internet.GetMacFromIp(ip);
     time      = DateTime.Now;
 }
Example #4
0
 public static string EnumToString(COMMU_TYPE type)
 {
     return(Rm.GetString("commu-type-" + type.ToString()));
 }