Modifier and Type | Field and Description |
---|---|
private int |
value
The model value.
|
Constructor and Description |
---|
IntegerModel(int value)
The constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
getValue()
Get the value.
|
void |
print(PrintHelper printer)
Add class-specific fields to the helper.
|
boolean |
setValue(int newValue)
Set the value.
|
addListener, changed, removeListener, toString
public IntegerModel(int value)
value
- the initial valuepublic int getValue()
public boolean setValue(int newValue)
newValue
- the new valuetrue
if model was changed as the result of this call.public void print(PrintHelper printer)
printer
- the string helper to update