jpower.irc.Network Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of JPower Show documentation
Show all versions of JPower Show documentation
Powerful Library for the JVM
package jpower.irc;
import java.util.List;
import java.util.ArrayList;
public class Network
{
private final String name;
private final String server;
private final int port;
private final String nickname;
private final String username;
private final String realname;
private List init_channels;
private PowerIrc instance;
public Network(String name, String server, int port, String nickname, String username, String realname)
{
this.name = name;
this.server = server;
this.port = port;
this.nickname = nickname;
this.username = username;
this.realname = realname;
init_channels = new ArrayList<>();
}
public void addInitChannel(String channel)
{
init_channels.add(channel);
}
public void connect()
{
instance = new PowerIrc(username, nickname, realname, server, port, init_channels);
instance.connect();
}
}