import net.pterodactylus.irc.event.ConnectionEstablished;
import net.pterodactylus.irc.util.MessageCleaner;
import net.pterodactylus.irc.util.RandomNickname;
+import net.pterodactylus.xdcc.core.event.CoreStarted;
import net.pterodactylus.xdcc.data.Bot;
import net.pterodactylus.xdcc.data.Channel;
import net.pterodactylus.xdcc.data.Network;
connection.start();
}
}
+
+ /* notify listeners. */
+ eventBus.post(new CoreStarted(this));
}
@Override
--- /dev/null
+/*
+ * XdccDownloader - CoreStarted.java - Copyright © 2013 David Roden
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+package net.pterodactylus.xdcc.core.event;
+
+import net.pterodactylus.xdcc.core.Core;
+
+/**
+ * Notifies all listeners that a {@link Core} was started.
+ *
+ * @author <a href="mailto:bombe@pterodactylus.net">David ‘Bombe’ Roden</a>
+ */
+public class CoreStarted {
+
+ /** The core that was started. */
+ private final Core core;
+
+ /**
+ * Creates a new core started event.
+ *
+ * @param core
+ * The core that was started
+ */
+ public CoreStarted(Core core) {
+ this.core = core;
+ }
+
+ //
+ // ACCESSORS
+ //
+
+ /**
+ * Returns the core that was started.
+ *
+ * @return The core that was started
+ */
+ public Core core() {
+ return core;
+ }
+
+}