import static net.pterodactylus.irc.event.ChannelNotJoined.Reason.inviteOnly;
import static net.pterodactylus.irc.event.ChannelNotJoined.Reason.registeredNicknamesOnly;
import static net.pterodactylus.irc.util.MessageCleaner.getDefaultInstance;
-import static net.pterodactylus.xdcc.data.Channel.TO_NETWORK;
import static net.pterodactylus.xdcc.data.Download.FILTER_RUNNING;
import java.io.File;
* @return All defined networks
*/
public Collection<Network> networks() {
- return FluentIterable.from(channels).transform(TO_NETWORK).toSet();
+ return FluentIterable.from(channels).transform(Channel::network).toSet();
}
/**
*/
public class Channel {
- /** Function to convert a channel to its network. */
- public static final Function<Channel, Network> TO_NETWORK = new Function<Channel, Network>() {
- @Override
- public Network apply(Channel channel) {
- return channel.network();
- }
- };
-
/** The network this channel belongs to. */
private final Network network;