com.groiss.store
Class ViewObject

java.lang.Object
  extended by com.groiss.store.ViewObject
All Implemented Interfaces:
Persistent, View

public abstract class ViewObject
extends java.lang.Object
implements Persistent, View


Constructor Summary
ViewObject()
           
 
Method Summary
 java.util.Vector dbFields()
          This method must return the persistent fields of this persistent object.
abstract  java.lang.String getBaseClassName()
           
 Persistent getBaseObject()
           
 long getOid()
          Getter method for the persistent object's OID.
 Store getStore()
          This method must return the Store object that is responsible for storing this persistent object.
 java.lang.String getTableName()
          This method must return the table name of the database table in which this persistent object is stored.
 boolean isFilled()
          With this method you check if this persistent object is filled with persistent data or not.
 void onDelete()
          This method is called before the persistent object is deleted.
 void onInsert()
          This method is called before the persistent object is inserted in the store.
 void onRead()
          This method is called after the persistent object has been read.
 void onUpdate()
          This method is called before the persistent object is updated to the store (the existing object in the store will be overwritten with the values of this object).
 void setBaseObject(Persistent baseObject)
           
 void setFilled(boolean f)
          This method can change the filled status of this persistent object.
 void setOid(long oid)
          Setter method for the persistent object's OID.
 void setStore(Store s)
          With this method you can change the Store of this persistent object.
 java.lang.String[] viewColumnNames()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ViewObject

public ViewObject()
Method Detail

getBaseClassName

public abstract java.lang.String getBaseClassName()
Specified by:
getBaseClassName in interface View

getBaseObject

public Persistent getBaseObject()
Specified by:
getBaseObject in interface View

setBaseObject

public void setBaseObject(Persistent baseObject)
Specified by:
setBaseObject in interface View

viewColumnNames

public java.lang.String[] viewColumnNames()
Specified by:
viewColumnNames in interface View

dbFields

public java.util.Vector dbFields()
Description copied from interface: Persistent
This method must return the persistent fields of this persistent object.

Specified by:
dbFields in interface Persistent
Returns:
vector of database fields
See Also:
Persistent.dbFields()

getOid

public long getOid()
Description copied from interface: Persistent
Getter method for the persistent object's OID.

Specified by:
getOid in interface Persistent
Returns:
the object ID
See Also:
Persistent.getOid()

getStore

public Store getStore()
Description copied from interface: Persistent
This method must return the Store object that is responsible for storing this persistent object.

Specified by:
getStore in interface Persistent
Returns:
the store
See Also:
Persistent.getStore()

getTableName

public java.lang.String getTableName()
Description copied from interface: Persistent
This method must return the table name of the database table in which this persistent object is stored.

Specified by:
getTableName in interface Persistent
Returns:
the table name
See Also:
Persistent.getTableName()

isFilled

public boolean isFilled()
Description copied from interface: Persistent
With this method you check if this persistent object is filled with persistent data or not. If it is not filled, you can use the Store to fill it.

Specified by:
isFilled in interface Persistent
Returns:
true if the object is filled
See Also:
Persistent.isFilled()

onDelete

public void onDelete()
              throws java.lang.Exception
Description copied from interface: Persistent
This method is called before the persistent object is deleted.

Specified by:
onDelete in interface Persistent
Throws:
java.lang.Exception
See Also:
Persistent.onDelete()

onInsert

public void onInsert()
              throws java.lang.Exception
Description copied from interface: Persistent
This method is called before the persistent object is inserted in the store.

Specified by:
onInsert in interface Persistent
Throws:
java.lang.Exception
See Also:
Persistent.onInsert()

onRead

public void onRead()
            throws java.lang.Exception
Description copied from interface: Persistent
This method is called after the persistent object has been read.

Specified by:
onRead in interface Persistent
Throws:
java.lang.Exception
See Also:
Persistent.onRead()

onUpdate

public void onUpdate()
              throws java.lang.Exception
Description copied from interface: Persistent
This method is called before the persistent object is updated to the store (the existing object in the store will be overwritten with the values of this object).

Specified by:
onUpdate in interface Persistent
Throws:
java.lang.Exception
See Also:
Persistent.onUpdate()

setFilled

public void setFilled(boolean f)
Description copied from interface: Persistent
This method can change the filled status of this persistent object. See Persistent.isFilled() for more details.

Specified by:
setFilled in interface Persistent
Parameters:
f -
See Also:
Persistent.setFilled(boolean)

setOid

public void setOid(long oid)
Description copied from interface: Persistent
Setter method for the persistent object's OID. Usually you will never need to set the OID of an object directly, because OIDs are assigned automatically.

Specified by:
setOid in interface Persistent
Parameters:
oid -
See Also:
Persistent.setOid(long)

setStore

public void setStore(Store s)
Description copied from interface: Persistent
With this method you can change the Store of this persistent object. Usually objects are stored in the system's database and you will never need to set the Store manually.

Specified by:
setStore in interface Persistent
Parameters:
s -
See Also:
Persistent.setStore(com.groiss.store.Store)


Copyright © 2001-2006 Groiss Informatics GmbH. All Rights Reserved.