org.opensubsystems.core.data
Class SimpleModifiableDataObject
java.lang.Object
org.opensubsystems.core.data.DataObject
org.opensubsystems.core.data.BasicDataObject
org.opensubsystems.core.data.ModifiableDataObject
org.opensubsystems.core.data.SimpleModifiableDataObject
- All Implemented Interfaces:
- java.io.Serializable
public final class SimpleModifiableDataObject
- extends ModifiableDataObject
- implements java.io.Serializable
This class is the simplest case of modifiable data object and it is useful in
situations when we need transfer only the most basic identification information
skipping the business data.
This class is made final so that nobody cannot derive from it new classes
since thats what the parent is for.
- Version:
- $Id: SimpleModifiableDataObject.java,v 1.5 2007/01/07 06:14:17 bastafidli Exp $
- Author:
- Martin Cerba
- See Also:
- Serialized Form
- Code reviewer:
- Miro Halas
- Code reviewed:
- 1.3 2005/09/07 16:36:02
|
Method Summary |
boolean |
isSame(java.lang.Object oObject)
Method to compare all data attributes of two objects to figure out, if
their attributes are the same. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
SimpleModifiableDataObject
public SimpleModifiableDataObject()
- Default constructor
SimpleModifiableDataObject
public SimpleModifiableDataObject(int iDomainId)
- Simple constructor creating new data object in particular domain.
- Parameters:
iDomainId - - domain this data object belongs to
SimpleModifiableDataObject
public SimpleModifiableDataObject(int iId,
int iDomainId,
java.sql.Timestamp creationTimestamp,
java.sql.Timestamp modificationTimestamp)
- Full constructor
- Parameters:
iId - - id of objectiDomainId - - domain idcreationTimestamp - - creation timestampmodificationTimestamp - - modification timestamp
SimpleModifiableDataObject
public SimpleModifiableDataObject(ModifiableDataObject data)
- Copy constructor.
- Parameters:
data - - source data object
isSame
public boolean isSame(java.lang.Object oObject)
- Method to compare all data attributes of two objects to figure out, if
their attributes are the same. The objects can for example differ by database
generated id and creation or modification timestamp but if other properties
which represents the real data are the same then the objects are considered
to be the same. This is weaker constraint that equals since not all
attributes has to be the same, only the one which really represents the
business data should match.
- Specified by:
isSame in class DataObject
- Parameters:
oObject - - Object to compare
- Returns:
- boolean - true if same, false otherwise
Copyright © 2003 - 2006 OpenSubsystems s.r.o.