com.mtp.model
Class DefaultIntegerModel

java.lang.Object
  |
  +--com.mtp.model.DefaultIntegerModel
All Implemented Interfaces:
IntegerModel

public class DefaultIntegerModel
extends Object
implements IntegerModel

Default implementation of an IntegerModel that just stores an 'int'.

Author:
Matthew Pekar

Field Summary
protected  Listeners listeners
           
protected  int value
           
 
Constructor Summary
DefaultIntegerModel()
           
DefaultIntegerModel(int val)
           
 
Method Summary
 void addListener(IntegerModelListener l)
           
 boolean equals(Object o)
           
 void fireChange()
           
 int getValue()
           
 void removeListener(IntegerModelListener l)
           
 void setValue(int val)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

value

protected int value

listeners

protected Listeners listeners
Constructor Detail

DefaultIntegerModel

public DefaultIntegerModel()

DefaultIntegerModel

public DefaultIntegerModel(int val)
Method Detail

equals

public boolean equals(Object o)
Overrides:
equals in class Object

getValue

public int getValue()
Specified by:
getValue in interface IntegerModel

setValue

public void setValue(int val)
Specified by:
setValue in interface IntegerModel

addListener

public void addListener(IntegerModelListener l)
Specified by:
addListener in interface IntegerModel

removeListener

public void removeListener(IntegerModelListener l)
Specified by:
removeListener in interface IntegerModel

fireChange

public void fireChange()


Copyright © 2002 Matthew Pekar. All Rights Reserved.