summaryrefslogtreecommitdiffstats
path: root/EssentialsUpdate/src/f00f/net/irc/martyr/replies/WhoisServerReply.java
diff options
context:
space:
mode:
Diffstat (limited to 'EssentialsUpdate/src/f00f/net/irc/martyr/replies/WhoisServerReply.java')
-rw-r--r--EssentialsUpdate/src/f00f/net/irc/martyr/replies/WhoisServerReply.java61
1 files changed, 61 insertions, 0 deletions
diff --git a/EssentialsUpdate/src/f00f/net/irc/martyr/replies/WhoisServerReply.java b/EssentialsUpdate/src/f00f/net/irc/martyr/replies/WhoisServerReply.java
new file mode 100644
index 000000000..d1f4d6344
--- /dev/null
+++ b/EssentialsUpdate/src/f00f/net/irc/martyr/replies/WhoisServerReply.java
@@ -0,0 +1,61 @@
+package f00f.net.irc.martyr.replies;
+
+import f00f.net.irc.martyr.InCommand;
+import f00f.net.irc.martyr.util.ParameterIterator;
+//import org.apache.log4j.Logger;
+
+public class WhoisServerReply extends AbstractWhoisReply
+{
+ //static Logger log = Logger.getLogger(WhoisServerReply.class);
+
+ private String serverName;
+ private String serverDesc;
+
+ /**
+ * Factory constructor.
+ * */
+ public WhoisServerReply()
+ {
+ }
+
+ public WhoisServerReply( String params )
+ {
+ super( params );
+ }
+
+ public String getIrcIdentifier()
+ {
+ return "312";
+ }
+
+ /**
+ * @return the DNS name of the server
+ * */
+ public String getServerName()
+ {
+ return serverName;
+ }
+
+ /**
+ * @return the free-form description of the server
+ * */
+ public String getServerDescription()
+ {
+ return serverDesc;
+ }
+
+ protected void parseParams( ParameterIterator pi )
+ {
+ serverName = (String)pi.next(); // Server name
+ serverDesc = (String)pi.next(); // Server description
+ //log.debug("WhoisServerReply: server name: " + serverName);
+ //log.debug("WhoisServerReply: server desc: " + serverDesc);
+ }
+
+ public InCommand parse( String prefix, String identifier, String params )
+ {
+ return new WhoisServerReply( params );
+ }
+
+}
+