f00f.net.irc.martyr.commands
Class UserCommand

java.lang.Object
  extended by f00f.net.irc.martyr.commands.UserCommand
All Implemented Interfaces:
Command, OutCommand

public class UserCommand
extends java.lang.Object
implements OutCommand

Defines USER command, part of the handshake to register on the network.


Field Summary
static java.lang.String IDENTIFIER
           
 
Constructor Summary
UserCommand(java.lang.String user, java.lang.String name, IRCConnection connection)
           
 
Method Summary
 java.lang.String getIrcIdentifier()
          Returns the string IRC uses to identify this command.
 java.lang.String render()
          Forms a string appropriate to send to the server, if required.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IDENTIFIER

public static final java.lang.String IDENTIFIER
See Also:
Constant Field Values
Constructor Detail

UserCommand

public UserCommand(java.lang.String user,
                   java.lang.String name,
                   IRCConnection connection)
Parameters:
user - the login name on the computer the client is on
name - the purported full name of the user, can be anything.
connection - the connection the user command is affiliated with
Method Detail

render

public java.lang.String render()
Description copied from interface: OutCommand
Forms a string appropriate to send to the server, if required. Some commands will have no such string, as they are received and not sent. The string returned is sent to the server verbatim.

Specified by:
render in interface OutCommand
Returns:
Rendered string

getIrcIdentifier

public java.lang.String getIrcIdentifier()
Description copied from interface: Command
Returns the string IRC uses to identify this command. Examples: NICK, PING, KILL, 332. Not strictly required for OutCommands as the irc identifier is expected to be part of the reder() result.

Specified by:
getIrcIdentifier in interface Command
Returns:
The IRC identifier string


Copyright © 2000-2007 Ben Damm, Daniel Henninger, et al.