RetrieveUser() public méthode

public RetrieveUser ( string nick ) : libirc.User
nick string
Résultat libirc.User
Exemple #1
0
        private static string GetSelfHost(Channel channel)
        {
            // try to get own hostname, if we can't find it, use default from configuration files
            string hostname = Configuration.IRC.Hostname;

            libirc.User self = channel.RetrieveUser(channel.PrimaryInstance.Nick);
            if (self != null)
            {
                hostname = self.Host;
            }
            return(hostname);
        }
Exemple #2
0
 public void GetOp(Channel chan)
 {
     if (!GetConfig(chan, "OP.Permanent", false))
     {
         chan.PrimaryInstance.irc.Queue.Send("CS op " + chan.Name, IRC.priority.high);
         return;
     }
     // get our user
     User user = chan.RetrieveUser(chan.PrimaryInstance.Nick);
     if (user == null)
     {
         chan.PrimaryInstance.irc.Queue.Send("CS op " + chan.Name, IRC.priority.high);
         return;
     }
     if (!user.IsOperator)
     {
         chan.PrimaryInstance.irc.Queue.Send("CS op " + chan.Name, IRC.priority.high);
     }
 }
Exemple #3
0
 private static string GetSelfHost(Channel channel)
 {
     // try to get own hostname, if we can't find it, use default from configuration files
     string hostname = Configuration.IRC.Hostname;
     libirc.User self = channel.RetrieveUser(channel.PrimaryInstance.Nick);
     if (self != null)
         hostname = self.Host;
     return hostname;
 }