All Packages Class Hierarchy This Package Previous Next Index
Class tc.message.ResultMessage
java.lang.Object
|
+----connection.Message
|
+----tc.message.ResultMessage
- public class ResultMessage
- extends Message
ResultMessage is a specialized message for sending response, e.g. from
the server to a client. The respons consists of a byte (usually either
constant OKAY or FAILED) and an arbitrary message string.
- Version:
- 0.30, 1998/04/01
- Author:
- FRED development team, Antti Viljamaa, Jukka Viljamaa
- See Also:
- Message
-
FAILED
- The status byte constant for negative response.
-
msg
- The message string.
-
OKAY
- The status byte constant for positive response.
-
status
- The status byte.
-
ResultMessage(byte)
- Initializes a new ResultMessage object with the given status byte.
-
ResultMessage(byte, byte)
- Initializes a new ResultMessage object with the given message id and
status byte.
-
ResultMessage(byte, byte, String)
- Initializes a new ResultMessage object with the given message id,
status byte, and message string.
-
ResultMessage(byte, String)
- Initializes a new ResultMessage object with the given status byte and
message string.
-
getMsg()
- Gets the message string.
-
getStatus()
- Gets the status byte.
-
setMsg(String)
- Sets the message string.
-
setStatus(byte)
- Sets the status byte.
OKAY
public static final byte OKAY
- The status byte constant for positive response.
FAILED
public static final byte FAILED
- The status byte constant for negative response.
msg
private String msg
- The message string.
status
private byte status
- The status byte.
ResultMessage
public ResultMessage(byte status)
- Initializes a new ResultMessage object with the given status byte.
- Parameters:
- status - The status byte.
ResultMessage
public ResultMessage(byte id,
byte status)
- Initializes a new ResultMessage object with the given message id and
status byte.
- Parameters:
- id - The optional message id. The user can use this
field to separate different messages that
use this same class.
- status - The status byte.
ResultMessage
public ResultMessage(byte status,
String msg)
- Initializes a new ResultMessage object with the given status byte and
message string.
- Parameters:
- status - The status byte.
- msg - The message string.
ResultMessage
public ResultMessage(byte id,
byte status,
String msg)
- Initializes a new ResultMessage object with the given message id,
status byte, and message string.
- Parameters:
- id - The optional message id. The user can use this
field to separate different messages that
use this same class.
- status - The status byte.
- msg - The message string.
getMsg
public String getMsg()
- Gets the message string.
getStatus
public byte getStatus()
- Gets the status byte.
setMsg
public void setMsg(String s)
- Sets the message string.
setStatus
public void setStatus(byte s)
- Sets the status byte.
All Packages Class Hierarchy This Package Previous Next Index