//private decimal _messageid = 0;
 //private decimal messageid { get { return _messageid; } set { _messageid = value; } }
 //private static decimal messageid = 0;
 public mLocatingConvert()
 {
     localdb.CommandTimeout = 0;
     _ciType = new ciType(false);
     _imeiTypeClass = new imeiTypeClass(false);
     _uriType = new uriType();
     _portType = new portType();
     _responseType = new responseType();
     _protocolType = new protocolType();
     _ipType = new ipType();
     //--删除
     //alter   table   你的表   drop   constraint   主键名
 }
Example #2
0
 private void uriTypeReverseIpType()
 {
     localdb = new DataClasses1DataContext(streamType.LocalConnString);
     //using (DataClasses1DataContext localdb = new DataClasses1DataContext(streamType.LocalConnString))
     //{
     uriType _uriType = new uriType();
     //http取上行包  ip_d
     var uri = from p in localdb.IP_stream
               select new
               {
                   curi = p.http_uri != null ? p.http_uri : null +
                          p.wsp_uri != null ? p.wsp_uri : null +
                          p.http_x_online != null ? p.http_x_online : null +
                          p.http_host != null ? p.http_host : null,
                   p.ip_d
               };
     var uriL = uri.Where(e => e.curi != null).ToLookup(e => e.curi);
     foreach (var t in uriL)
         foreach (var t1 in t)
             if (_uriType.d.ContainsKey(t.Key))
                 if (!dIP.ContainsKey(t1.ip_d))
                     dIP.Add(t1.ip_d, _uriType.ConvertUri2trType(t.Key));
     //}
 }