|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Mode
Any class which is to represent a mode must implement this interface. They must also implement equals(...) so that if the parameter for either mode is null they are equal based on the character, and if both parameters are not null, base the equal on the character and the parameters being equal.
Nested Class Summary | |
---|---|
static class |
Mode.Sign
Finally, the Sign enumeration. |
Method Summary | |
---|---|
char |
getChar()
The character that represents this mode (ie o for operator) |
java.lang.String |
getParam()
Returns the parameter that was set with setParam(...) |
Mode.Sign |
getSign()
|
Mode |
newInstance()
A Mode can be constructed and asked to make copies of itself. |
boolean |
onePerChannel()
Determines if there can be multiple versions of this mode in the channel. |
boolean |
recordInChannel()
This mode should be recorded in the list of channel modes. |
boolean |
requiresParam()
Should return true if this mode requires a parameter. |
void |
setParam(java.lang.String str)
Sets the parameter that can be retrieved with getParam() |
void |
setSign(Mode.Sign sign)
Sets the sign of the operation. |
Method Detail |
---|
Mode newInstance()
char getChar()
boolean requiresParam()
boolean recordInChannel()
boolean onePerChannel()
java.lang.String getParam()
void setParam(java.lang.String str)
str
- Parameter to set on modevoid setSign(Mode.Sign sign)
sign
- Sign (+/-) of the modeMode.Sign getSign()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |