🚧 Parse token from DCC SEND
[xudocci.git] / src / main / java / net / pterodactylus / irc / event / DccSendReceived.java
index 95494a4..b3f8bd6 100644 (file)
@@ -44,29 +44,16 @@ public class DccSendReceived extends AbstractConnectionEvent {
        /** The filesize. */
        private final long filesize;
 
-       /**
-        * Creates a new DCC SEND received event.
-        *
-        * @param connection
-        *              The connetion the event occured on
-        * @param source
-        *              The source offering the file
-        * @param filename
-        *              The name of the file being offered
-        * @param inetAddress
-        *              The IP address of the source
-        * @param port
-        *              The port number of the source
-        * @param filesize
-        *              The size of the file being offered ({@code -1} for unknown size)
-        */
-       public DccSendReceived(Connection connection, Source source, String filename, InetAddress inetAddress, int port, long filesize) {
+       private final String token;
+
+       public DccSendReceived(Connection connection, Source source, String filename, InetAddress inetAddress, int port, long filesize, String token) {
                super(connection);
                this.source = source;
                this.filename = filename;
                this.inetAddress = inetAddress;
                this.port = port;
                this.filesize = filesize;
+               this.token = token;
        }
 
        //
@@ -120,4 +107,8 @@ public class DccSendReceived extends AbstractConnectionEvent {
                return port;
        }
 
+       public String token() {
+               return token;
+       }
+
 }