public class IrcStack extends java.lang.Object implements IrcConnectionListener
Modifier and Type | Class and Description |
---|---|
(package private) static class |
IrcStack.PersistentContext
Persistent context that is used to survive (dis)connects.
|
Constructor and Description |
---|
IrcStack(ProtocolProviderServiceIrcImpl parentProvider,
java.lang.String nick,
java.lang.String login,
java.lang.String version,
java.lang.String finger)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
connect(java.lang.String host,
int port,
java.lang.String password,
boolean secureConnection,
boolean autoNickChange,
ClientConfig config)
Connect to specified host, port, optionally using a password.
|
void |
connectionInterrupted(IrcConnection connection)
Event for any kind of connection interruption, including normal QUIT
events.
|
void |
disconnect()
Disconnect from the IRC server.
|
void |
dispose()
Dispose.
|
IrcConnection |
getConnection()
Get the current connection instance.
|
(package private) IrcStack.PersistentContext |
getContext()
Get the stack's persistent context instance.
|
public IrcStack(ProtocolProviderServiceIrcImpl parentProvider, java.lang.String nick, java.lang.String login, java.lang.String version, java.lang.String finger)
parentProvider
- Parent providernick
- User's nick namelogin
- User's login nameversion
- Versionfinger
- Fingerpublic void connect(java.lang.String host, int port, java.lang.String password, boolean secureConnection, boolean autoNickChange, ClientConfig config) throws OperationFailedException, java.lang.Exception
host
- IRC server's host nameport
- IRC portpassword
- password for the specified nick namesecureConnection
- true to set up secure connection, or false if
not.autoNickChange
- do automatic nick changes if nick is in useconfig
- Client configurationOperationFailedException
- in case of user canceling because of
certificate errorsjava.lang.Exception
- throws exceptionspublic IrcConnection getConnection()
IrcStack.PersistentContext getContext()
public void disconnect()
public void dispose()
public void connectionInterrupted(IrcConnection connection)
connectionInterrupted
in interface IrcConnectionListener
connection
- the connection that gets interrupted
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.