From ea192ddd6d5b538e0bd0f6f1721890eb3c25de30 Mon Sep 17 00:00:00 2001 From: snowleo Date: Wed, 12 Oct 2011 03:14:07 +0200 Subject: EssentialsUpdate WIP --- .../net/irc/martyr/errors/TooManyTargetsError.java | 47 ++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 EssentialsUpdate/src/f00f/net/irc/martyr/errors/TooManyTargetsError.java (limited to 'EssentialsUpdate/src/f00f/net/irc/martyr/errors/TooManyTargetsError.java') diff --git a/EssentialsUpdate/src/f00f/net/irc/martyr/errors/TooManyTargetsError.java b/EssentialsUpdate/src/f00f/net/irc/martyr/errors/TooManyTargetsError.java new file mode 100644 index 000000000..594fe4e41 --- /dev/null +++ b/EssentialsUpdate/src/f00f/net/irc/martyr/errors/TooManyTargetsError.java @@ -0,0 +1,47 @@ +package f00f.net.irc.martyr.errors; + +import f00f.net.irc.martyr.InCommand; + +/** + * Code: 407 ERR_TOOMANYTARGETS + * <target> :Duplicate recipients. No message delivered + * Returned to a client which is attempting to send a PRIVMSG/NOTICE using the user@host destination + * format and for a user@host which has several occurrences. + */ +public class TooManyTargetsError extends GenericError +{ + private String dest; + private String errorMessage; + + public TooManyTargetsError() + { + } + + public TooManyTargetsError(String dest, String errorMessage) + { + this.dest = dest; + this.errorMessage = errorMessage; + } + + public String getIrcIdentifier() + { + return "407"; + } + + public InCommand parse( String prefix, String identifier, String params ) + { + return new TooManyTargetsError(getParameter(params, 1), getParameter(params, 2)); + } + + public String getDest() + { + return dest; + } + + public String getErrorMessage() + { + return errorMessage; + } + +} + -- cgit v1.2.3