com.objectwave.persist.examples
Class TestEntity
java.lang.Object
|
+--com.objectwave.persist.examples.DomainObject
|
+--com.objectwave.persist.examples.TestEntity
- All Implemented Interfaces:
- Persistence, java.io.Serializable, TransactionalObjectIF
- public class TestEntity
- extends DomainObject
- Version:
- $Id: TestEntity.java,v 2.0 2001/06/11 16:00:04 dave_hoag Exp $
- See Also:
- Serialized Form
Methods inherited from class com.objectwave.persist.examples.DomainObject |
addDefaultPrimaryAttribute, createAdapter, delete, getAdapter, getBrokerName, getClassDescriptor, getEntry, getObjectEditor, getObjectIdentifier, getPrimaryKeyField, getPrimaryKeyFields, getSuperDescriptor, getTableName, getXmlDefinition, initDescription, initDescriptor, initializeObjectEditor, insert, isDirty, isRetrievedFromDatabase, isTransient, locateXmlMap, lock, markForDelete, save, setAsTransient, setBrokerName, setClassDescriptor, setEntry, setObjectEditor, setObjectIdentifier, setPrimaryKeyField, setPrintString, setRetrievedFromDatabase, setTableName, toString, unlock, usesAdapter |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
PERSON
public static final int PERSON
- See Also:
- Constant Field Values
COMPANY
public static final int COMPANY
- See Also:
- Constant Field Values
name
public java.lang.String name
phone
public java.lang.String phone
fax
public java.lang.String fax
title
public java.lang.String title
annualIncome
public double annualIncome
TestEntity
public TestEntity()
createInstance
protected static Persistence createInstance(RDBPersistence refObj,
RDBPersistence origObj,
java.lang.Object classValue)
- Create a new instance of the correct type based on the value
of classValue.
- Parameters:
refObj
- com.objectwave.persist.RDBPersistenceclassValue
- java.lang.Object
- Returns:
- com.objectwave.persist.Persistence
getAnnualIncome
protected double getAnnualIncome()
getFax
protected java.lang.String getFax()
getMoodyRating
protected java.lang.String getMoodyRating()
getName
public java.lang.String getName()
getNumEmployees
protected int getNumEmployees()
getPhone
public java.lang.String getPhone()
getTitle
protected java.lang.String getTitle()
initDescriptor
public void initDescriptor()
- Describe how this class relates to the relational database.
initializeObjectEditor
public ObjectEditingView initializeObjectEditor()
- Needed to define table name and the description of this class.
- Overrides:
initializeObjectEditor
in class DomainObject
- Returns:
main
public static void main(java.lang.String[] args)
- Parameters:
args
- java.lang.String[]
setAnnualIncome
protected void setAnnualIncome(double aValue)
setFax
public void setFax(java.lang.String aValue)
setMoodyRating
protected void setMoodyRating(java.lang.String aValue)
setName
public void setName(java.lang.String aValue)
setNumEmployees
protected void setNumEmployees(int aValue)
setPhone
protected void setPhone(java.lang.String aValue)
setTitle
protected void setTitle(java.lang.String aValue)
update
public void update(boolean get,
java.lang.Object[] data,
java.lang.reflect.Field[] fields)
- This method allows me to get arounds security problems with updating
and object from a generic framework.
- Specified by:
update
in interface TransactionalObjectIF
- Overrides:
update
in class DomainObject
- Parameters:
get
- data
- fields
-