hudson.plugins.ircbot.v2
Class IRCConnection

java.lang.Object
  extended by hudson.plugins.ircbot.v2.IRCConnection
All Implemented Interfaces:
hudson.plugins.im.IMConnection, PircConnection.InviteListener, PircConnection.JoinListener, PircConnection.PartListener

public class IRCConnection
extends java.lang.Object
implements hudson.plugins.im.IMConnection, PircConnection.JoinListener, PircConnection.InviteListener, PircConnection.PartListener


Constructor Summary
IRCConnection(IrcPublisher.DescriptorImpl descriptor, hudson.plugins.im.AuthenticationHolder authentication)
           
 
Method Summary
 void addConnectionListener(hudson.plugins.im.IMConnectionListener listener)
           
 void channelJoined(java.lang.String channelName)
          Is called when the ircbot joins a channel.
 void channelParted(java.lang.String channelName)
          Is called when the ircbot is disconnected (leaves or is kicked) from a channel.
 void close()
           
 boolean connect()
           
 void inviteReceived(java.lang.String channelName, java.lang.String inviter)
          Is called when the ircbot is invited to a channel.
 boolean isConnected()
           
 void removeConnectionListener(hudson.plugins.im.IMConnectionListener listener)
           
 void send(hudson.plugins.im.IMMessageTarget target, java.lang.String text)
           
 void setPresence(hudson.plugins.im.IMPresence presence, java.lang.String statusMessage)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IRCConnection

public IRCConnection(IrcPublisher.DescriptorImpl descriptor,
                     hudson.plugins.im.AuthenticationHolder authentication)
Method Detail

close

public void close()
Specified by:
close in interface hudson.plugins.im.IMConnection

isConnected

public boolean isConnected()
Specified by:
isConnected in interface hudson.plugins.im.IMConnection

connect

public boolean connect()
Specified by:
connect in interface hudson.plugins.im.IMConnection

channelJoined

public void channelJoined(java.lang.String channelName)
Description copied from interface: PircConnection.JoinListener
Is called when the ircbot joins a channel.

Specified by:
channelJoined in interface PircConnection.JoinListener

inviteReceived

public void inviteReceived(java.lang.String channelName,
                           java.lang.String inviter)
Description copied from interface: PircConnection.InviteListener
Is called when the ircbot is invited to a channel.

Specified by:
inviteReceived in interface PircConnection.InviteListener

channelParted

public void channelParted(java.lang.String channelName)
Description copied from interface: PircConnection.PartListener
Is called when the ircbot is disconnected (leaves or is kicked) from a channel.

Specified by:
channelParted in interface PircConnection.PartListener

addConnectionListener

public void addConnectionListener(hudson.plugins.im.IMConnectionListener listener)
Specified by:
addConnectionListener in interface hudson.plugins.im.IMConnection

removeConnectionListener

public void removeConnectionListener(hudson.plugins.im.IMConnectionListener listener)
Specified by:
removeConnectionListener in interface hudson.plugins.im.IMConnection

send

public void send(hudson.plugins.im.IMMessageTarget target,
                 java.lang.String text)
          throws hudson.plugins.im.IMException
Specified by:
send in interface hudson.plugins.im.IMConnection
Throws:
hudson.plugins.im.IMException

setPresence

public void setPresence(hudson.plugins.im.IMPresence presence,
                        java.lang.String statusMessage)
                 throws hudson.plugins.im.IMException
Specified by:
setPresence in interface hudson.plugins.im.IMConnection
Throws:
hudson.plugins.im.IMException


Copyright © 2011. All Rights Reserved.