public class VersionImpl extends de.willuhn.datasource.db.AbstractDBObject implements Version
CREATE TABLE version ( id NUMERIC default UNIQUEKEY('version'), name varchar(255) NOT NULL, version int(5) NOT NULL, UNIQUE (id), PRIMARY KEY (id) );Getters und Setters für den Primary Key (id) sind nicht nötig. Jede Methode muss zwingend eine RemoteException werfen.
Constructor and Description |
---|
VersionImpl()
Standart Konstruktor
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getName()
Liefert den Namen der Version.
|
java.lang.String |
getPrimaryAttribute() |
protected java.lang.String |
getTableName() |
int |
getVersion()
Liefert den aktuellen Stand der Version.
|
void |
insert() |
protected void |
insertCheck() |
void |
setName(java.lang.String name)
Speichert den Namen der Version.
|
void |
setVersion(int newVersion)
Legt die neue Versionsnummer fest.
|
protected void |
updateCheck() |
addDeleteListener, addStoreListener, clear, delete, deleteCheck, equals, getAttribute, getAttributeNames, getAttributeType, getForeignObject, getID, getIDField, getInsertSQL, getList, getListQuery, getLoadQuery, getService, getUpdateSQL, hasChanged, hasChanged, init, isNewObject, load, overwrite, removeDeleteListener, removeStoreListener, setAttribute, setID, setService, store, transactionBegin, transactionCommit, transactionRollback
clone, exportObject, exportObject, exportObject, unexportObject
equals, getRef, hashCode, toString, toStub
finalize, getClass, notify, notifyAll, wait, wait, wait
addDeleteListener, addStoreListener, equals, getAttribute, getAttributeType, getList, load, removeDeleteListener, removeStoreListener
public VersionImpl() throws java.rmi.RemoteException
java.rmi.RemoteException
public java.lang.String getName() throws java.rmi.RemoteException
Version
getName
in interface Version
java.rmi.RemoteException
Version.getName()
public java.lang.String getPrimaryAttribute() throws java.rmi.RemoteException
getPrimaryAttribute
in interface de.willuhn.datasource.GenericObject
getPrimaryAttribute
in interface de.willuhn.datasource.rmi.DBObject
getPrimaryAttribute
in class de.willuhn.datasource.db.AbstractDBObject
java.rmi.RemoteException
AbstractDBObject.getPrimaryAttribute()
public int getVersion() throws java.rmi.RemoteException
Version
getVersion
in interface Version
java.rmi.RemoteException
Version.getVersion()
public void insert() throws java.rmi.RemoteException, de.willuhn.util.ApplicationException
insert
in class de.willuhn.datasource.db.AbstractDBObject
java.rmi.RemoteException
de.willuhn.util.ApplicationException
AbstractDBObject.insert()
public void setName(java.lang.String name) throws java.rmi.RemoteException
Version
setName
in interface Version
name
- Name der Version.java.rmi.RemoteException
Version.setName(java.lang.String)
public void setVersion(int newVersion) throws java.rmi.RemoteException
Version
setVersion
in interface Version
newVersion
- die neue Versionsnummer.java.rmi.RemoteException
Version.setVersion(int)
protected java.lang.String getTableName()
getTableName
in class de.willuhn.datasource.db.AbstractDBObject
AbstractDBObject.getTableName()
protected void insertCheck() throws de.willuhn.util.ApplicationException
insertCheck
in class de.willuhn.datasource.db.AbstractDBObject
de.willuhn.util.ApplicationException
AbstractDBObject.insertCheck()
protected void updateCheck() throws de.willuhn.util.ApplicationException
updateCheck
in class de.willuhn.datasource.db.AbstractDBObject
de.willuhn.util.ApplicationException
AbstractDBObject.updateCheck()