예제 #1
0
 private bool IdleTime(Network.IncomingDataEventArgs info)
 {
     Network.NetworkWHOISEventArgs ev = new Network.NetworkWHOISEventArgs(this.ServerLineRawText, this.Date);
     ev.Source = info.Source;
     ev.Parameters = info.Parameters;
     ev.ParameterLine = info.ParameterLine;
     ev.WhoisType = Network.NetworkWHOISEventArgs.Mode.Uptime;
     _Network.__evt_WHOIS(ev);
     return true;
 }
예제 #2
0
 private bool WhoisText(Network.IncomingDataEventArgs info)
 {
     Network.NetworkWHOISEventArgs ev = new Network.NetworkWHOISEventArgs(this.ServerLineRawText, this.Date);
     ev.WhoisType = Network.NetworkWHOISEventArgs.Mode.Info;
     ev.Parameters = info.Parameters;
     ev.Message = info.Message;
     ev.ParameterLine = info.ParameterLine;
     _Network.__evt_WHOIS(ev);
     return true;
 }
예제 #3
0
 /// <summary>
 /// Parsing last line of whois
 /// </summary>
 /// <param name="source"></param>
 /// <param name="parameters"></param>
 /// <param name="value"></param>
 /// <returns></returns>
 private bool WhoisFn(string source, string parameters)
 {
     Network.NetworkWHOISEventArgs ev = new Network.NetworkWHOISEventArgs(this.ServerLineRawText, this.Date);
     ev.WhoisType = Network.NetworkWHOISEventArgs.Mode.Footer;
     ev.ParameterLine = parameters;
     ev.Source = source;
     _Network.__evt_WHOIS(ev);
     return true;
 }
예제 #4
0
 /// <summary>
 /// Parsing the line of whois text
 /// </summary>
 /// <param name="source"></param>
 /// <param name="parameters"></param>
 /// <param name="value"></param>
 /// <returns></returns>
 private bool WhoisSv(Network.IncomingDataEventArgs info)
 {
     if (info.ParameterLine.Contains(" "))
     {
         string name = info.ParameterLine.Substring(info.ParameterLine.IndexOf(" ", StringComparison.Ordinal) + 1);
         if (!name.Contains(" "))
         {
             _Protocol.DebugLog("Invalid whois record " + info.ParameterLine);
             return false;
         }
         Network.NetworkWHOISEventArgs ev = new Network.NetworkWHOISEventArgs(this.ServerLineRawText, this.Date);
         ev.ParameterLine = info.ParameterLine;
         ev.Parameters = info.Parameters;
         ev.Message = info.Message;
         ev.WhoisType = Network.NetworkWHOISEventArgs.Mode.Server;
         ev.WhoisLine = name.Substring(name.IndexOf(" ", StringComparison.Ordinal) + 1);
         ev.Source = name.Substring(0, name.IndexOf(" ", StringComparison.Ordinal));
         _Network.__evt_WHOIS(ev);
         return true;
     }
     return false;
 }
예제 #5
0
 /// <summary>
 /// Parsing the channels of whois
 /// </summary>
 /// <param name="source"></param>
 /// <param name="parameters"></param>
 /// <param name="value"></param>
 /// <returns></returns>
 private bool WhoisCh(string source, string parameters, string value)
 {
     if (parameters.Contains(" "))
     {
         Network.NetworkWHOISEventArgs ev = new Network.NetworkWHOISEventArgs(this.ServerLineRawText, this.Date);
         ev.WhoisType = Network.NetworkWHOISEventArgs.Mode.Channels;
         ev.Source = source;
         ev.Message = value;
         ev.ParameterLine = parameters;
         _Network.__evt_WHOIS(ev);
         return true;
     }
     return false;
 }