rheise.jftpd
Class CommandException
java.lang.Object
|
+--java.lang.Throwable
|
+--java.lang.Exception
|
+--rheise.jftpd.CommandException
- public class CommandException
- extends java.lang.Exception
This exception is thrown if there is an error handling any user command.
- See Also:
- Serialized Form
Field Summary |
private int |
code
The reply code to send to the user. |
private java.lang.String |
text
The text message to send with the reply code. |
Fields inherited from class java.lang.Throwable |
backtrace,
detailMessage,
serialVersionUID |
Constructor Summary |
CommandException(int code,
java.lang.String text)
Creates a new CommandException. |
Method Summary |
int |
getCode()
|
java.lang.String |
getMessage()
Throwable.getMessage() returns the message passed into the
constructor. |
java.lang.String |
getText()
|
Methods inherited from class java.lang.Throwable |
fillInStackTrace,
getLocalizedMessage,
printStackTrace,
printStackTrace,
printStackTrace,
printStackTrace0,
toString |
Methods inherited from class java.lang.Object |
,
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
wait,
wait,
wait |
code
private int code
- The reply code to send to the user.
text
private java.lang.String text
- The text message to send with the reply code.
CommandException
public CommandException(int code,
java.lang.String text)
- Creates a new CommandException.
- Parameters:
code
- the reply code.text
- the associated error message.
getCode
public int getCode()
- Returns:
- the reply code.
getText
public java.lang.String getText()
- Returns:
- the reply text.
getMessage
public java.lang.String getMessage()
- Throwable.getMessage() returns the message passed into the
constructor. CommandException does not use this argument so
getMessage() is overridden to return a string constructed from the
exception code and text.
- Overrides:
- getMessage in class java.lang.Throwable