|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IOption
Interface of the settable option. The settable option is used for game options which relate to game behavior and as well as pilot options which relate to specific stats about a pilot, such as advantages. Game options are the same across all clients. A settable option's primary purpose is to store a value for the option. Its secondary purpose is to give the desired options dialog enough data to allow the user to set the option.
| Field Summary | |
|---|---|
static int |
BOOLEAN
Booolean option type |
static int |
CHOICE
Choise option type |
static int |
FLOAT
Float option type |
static int |
INTEGER
Integer option type |
static int |
STRING
String option type |
| Method Summary | |
|---|---|
boolean |
booleanValue()
Return the value as the boolean |
void |
clearValue()
Resets the value to its "default" state |
float |
floatValue()
Return the value as the float |
java.lang.Object |
getDefault()
Returns default option value |
IOptions |
getOwner()
Returns this option container - GameOptions, PilotOptions etc |
int |
getType()
Returns option type. |
int |
intValue()
Return the value as the int |
void |
setValue(boolean value)
Sets the boolean value |
void |
setValue(float value)
Sets the float value |
void |
setValue(int value)
Sets the int value |
void |
setValue(java.lang.Object value)
Sets the value |
void |
setValue(java.lang.String value)
Sets the String value |
java.lang.String |
stringValue()
Return the value as the String |
| Methods inherited from interface megamek.common.options.IBasicOption |
|---|
getName, getValue |
| Methods inherited from interface megamek.common.options.IOptionInfo |
|---|
getDescription, getDisplayableName, getDisplayableNameWithValue, getTextFieldLength, isLabelBeforeTextField |
| Field Detail |
|---|
static final int BOOLEAN
static final int INTEGER
static final int FLOAT
static final int STRING
static final int CHOICE
| Method Detail |
|---|
IOptions getOwner()
int getType()
etcjava.lang.Object getDefault()
boolean booleanValue()
boolean
int intValue()
int
float floatValue()
float
java.lang.String stringValue()
String
void setValue(java.lang.Object value)
value - value to setvoid setValue(java.lang.String value)
String value
value - value to setvoid setValue(boolean value)
boolean value
value - value to setvoid setValue(int value)
int value
value - value to setvoid setValue(float value)
float value
value - value to setvoid clearValue()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||