|
|||||||||
| Home >> All >> org >> modama >> framework >> [ entities overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.modama.framework.entities
Class NumberEntity

java.lang.Objectorg.modama.ModelStates
org.modama.Model
org.modama.framework.AbstractFrameworkModel
org.modama.framework.entities.AbstractEntity
org.modama.framework.entities.NumberEntity
- public class NumberEntity
- extends AbstractEntity
A Number entity. just a number (currently a double) 05/10/03 - synopia - added toString();
| Field Summary | |
(package private) java.lang.Double |
data
the number |
| Fields inherited from class org.modama.framework.entities.AbstractEntity |
fullName, ID, IDcnt, PROP_DATA, PROP_FULLNAME |
| Fields inherited from class org.modama.framework.AbstractFrameworkModel |
name, PROP_NAME |
| Fields inherited from class org.modama.Model |
changeAgent, EVENT_FIRED, state |
| Fields inherited from class org.modama.ModelStates |
CREATED, DELETED, MODIFIED, SAVED |
| Constructor Summary | |
NumberEntity()
the interval for the number |
|
NumberEntity(java.lang.String initName)
|
|
| Method Summary | |
protected void |
create()
create the number with some initial values |
void |
delete()
delete the entity from the world |
java.lang.Object |
getData()
getter for data |
java.lang.Double |
getNumber()
|
boolean |
isEmpty()
get set methods |
boolean |
load(java.net.URL url)
tries to load the number from the url, expects just a simple string representing the number |
void |
save(java.net.URL url)
saves the number to a file using a FileWriter |
void |
setData(java.lang.Object data)
setter for data, cause fire |
void |
setNumber(java.lang.Double d)
|
java.lang.String |
toString()
Convert this Object to a human-readable String. |
| Methods inherited from class org.modama.framework.entities.AbstractEntity |
getFullName, getID, setFullName |
| Methods inherited from class org.modama.framework.AbstractFrameworkModel |
getName, setName |
| Methods inherited from class org.modama.Model |
addPropertyChangeListener, addPropertyChangeListener, fire, fire, fire, getState, removePropertyChangeListener, removePropertyChangeListener, setState |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
data
java.lang.Double data
- the number
| Constructor Detail |
NumberEntity
public NumberEntity()
- the interval for the number
NumberEntity
public NumberEntity(java.lang.String initName)
| Method Detail |
create
protected void create()
- create the number with some initial values
- Overrides:
createin classAbstractEntity
delete
public void delete()
throws org.modama.framework.exceptions.DeleteCancelledException
- Description copied from class:
AbstractEntity - delete the entity from the world
- Overrides:
deletein classAbstractEntity
load
public boolean load(java.net.URL url) throws java.io.IOException
- tries to load the number from the url, expects just a simple string representing the number
save
public void save(java.net.URL url) throws java.io.IOException
- saves the number to a file using a FileWriter
isEmpty
public boolean isEmpty()
- get set methods
- Specified by:
isEmptyin classAbstractEntity
getData
public java.lang.Object getData()
- Description copied from class:
AbstractEntity - getter for data
- Specified by:
getDatain classAbstractEntity
setData
public void setData(java.lang.Object data)
- Description copied from class:
AbstractEntity - setter for data, cause fire
- Specified by:
setDatain classAbstractEntity
getNumber
public java.lang.Double getNumber()
setNumber
public void setNumber(java.lang.Double d)
toString
public java.lang.String toString()
- Description copied from class:
java.lang.Object - Convert this Object to a human-readable String.
There are no limits placed on how long this String
should be or what it should contain. We suggest you
make it as intuitive as possible to be able to place
it into System.out.println() 55
and such.
It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.
This method will be called when performing string concatenation with this object. If the result is
null, string concatenation will instead use"null".The default implementation returns
getClass().getName() + "@" + Integer.toHexString(hashCode()).
|
|||||||||
| Home >> All >> org >> modama >> framework >> [ entities overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC