Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

openfuture.bugbase.domain
Class DomainObject  view DomainObject download DomainObject.java

java.lang.Object
  extended byopenfuture.bugbase.domain.DomainObject
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
BugReport, Login

public class DomainObject
extends java.lang.Object
implements java.io.Serializable

Base class for domain objects. Handles the state of domain objects. Created: Fri Jun 09 03:46:29 2000

Version:
$Revision: 1.3 $

Field Summary
private  int state
           
static int STATE_CLEAN
           
static int STATE_DELETED
           
static int STATE_DIRTY
           
static int STATE_NEW
           
 
Constructor Summary
DomainObject()
           
 
Method Summary
protected  int getState()
          Get the value of state.
 boolean isDeleted()
          Returns true, if the domain object is deleted.
 boolean isDirty()
          Returns true, if the domain object is dirty.
 boolean isNew()
          Returns true, if the domain object is new.
 void setClean()
          Sets the state to 'clean'.
 void setDirty()
          Sets the state to 'dirty'.
 void setModified()
          State set to STATE_DIRTY except for STATE_NEW.
protected  void setState(int v)
          Set the value of state.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STATE_NEW

public static final int STATE_NEW
See Also:
Constant Field Values

STATE_CLEAN

public static final int STATE_CLEAN
See Also:
Constant Field Values

STATE_DIRTY

public static final int STATE_DIRTY
See Also:
Constant Field Values

STATE_DELETED

public static final int STATE_DELETED
See Also:
Constant Field Values

state

private int state
Constructor Detail

DomainObject

public DomainObject()
Method Detail

setModified

public void setModified()
State set to STATE_DIRTY except for STATE_NEW.


setDirty

public void setDirty()
Sets the state to 'dirty'.


setClean

public void setClean()
Sets the state to 'clean'.


isDirty

public boolean isDirty()
Returns true, if the domain object is dirty.


isNew

public boolean isNew()
Returns true, if the domain object is new.


isDeleted

public boolean isDeleted()
Returns true, if the domain object is deleted.


getState

protected int getState()
Get the value of state.


setState

protected void setState(int v)
Set the value of state.