com.melloware.jukes.db.orm
Class AbstractJukesObject

java.lang.Object
  extended by com.jgoodies.binding.beans.Model
      extended by com.melloware.jukes.db.orm.AbstractJukesObject
All Implemented Interfaces:
com.jgoodies.binding.beans.Observable, java.io.Serializable
Direct Known Subclasses:
Artist, Catalog, Disc, Track

public abstract class AbstractJukesObject
extends com.jgoodies.binding.beans.Model
implements java.io.Serializable

Base class for all domain ORM objects.

Copyright (c) 1999-2007 Melloware, Inc.

Version:
4.0
Author:
Emil A. Lefkof III
See Also:
Model, Serialized Form

Field Summary
protected  int childCount
           
protected  boolean newFile
           
static int NO_CHILDREN
           
protected  boolean valid
           
 
Constructor Summary
AbstractJukesObject()
           
 
Method Summary
abstract  java.util.Date getAuditDate()
          Date will be used to determine new-ness.
abstract  int getChildCount()
          Method implemented in each ORM class.
abstract  java.util.Date getCreatedDate()
          Method implemented in each ORM class.
abstract  java.lang.Long getId()
          All objects must implement a unique identifier.
abstract  java.util.Date getModifiedDate()
          Method implemented in each ORM class.
abstract  java.lang.String getName()
          All objects must implement a name function to describe this object.
 boolean isNewFile(int aDays)
          Gets whether this file is considered new by checking the number of days against aDays.
 boolean isNotValid()
          Gets the valid flag.
abstract  boolean isValid()
          Gets the valid flag.
 void setChildCount(int count)
          Sets the Child count.
 void setNewFile(boolean aNewFile)
          Sets the newFile.
 void setValid(boolean aValid)
          Sets the valid.
 
Methods inherited from class com.jgoodies.binding.beans.Model
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, equals, fireMulticastPropertyChange, fireMultiplePropertiesChanged, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getPropertyChangeListeners, getPropertyChangeListeners, getVetoableChangeListeners, getVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NO_CHILDREN

public static final int NO_CHILDREN
See Also:
Constant Field Values

newFile

protected boolean newFile

valid

protected boolean valid

childCount

protected int childCount
Constructor Detail

AbstractJukesObject

public AbstractJukesObject()
Method Detail

getName

public abstract java.lang.String getName()
All objects must implement a name function to describe this object.

Returns:
the name of the object

getId

public abstract java.lang.Long getId()
All objects must implement a unique identifier.

Returns:
the id of the object

getChildCount

public abstract int getChildCount()
Method implemented in each ORM class. If it has some sort of child return the count else return 0. This is used for lazy loading the tree nodes.

Returns:
the count of the children or 0 if no children

getAuditDate

public abstract java.util.Date getAuditDate()
Date will be used to determine new-ness.

Returns:
the audit date to determine new-ness

getModifiedDate

public abstract java.util.Date getModifiedDate()
Method implemented in each ORM class. This returns the audit modified date.

Returns:
the modification date

getCreatedDate

public abstract java.util.Date getCreatedDate()
Method implemented in each ORM class. This returns the audit created date.

Returns:
the created date

isValid

public abstract boolean isValid()
Gets the valid flag.

Returns:
Returns the valid flag.

isNotValid

public boolean isNotValid()
Gets the valid flag.

Returns:
Returns the valid flag.

setChildCount

public void setChildCount(int count)
Sets the Child count.

Parameters:
count - the count to set it to.

setNewFile

public void setNewFile(boolean aNewFile)
Sets the newFile.

Parameters:
aNewFile - The newFile to set.

setValid

public void setValid(boolean aValid)
Sets the valid.

Parameters:
aValid - The valid to set.

isNewFile

public boolean isNewFile(int aDays)
Gets whether this file is considered new by checking the number of days against aDays.

Parameters:
aDays - the number of days past a file is considered new
Returns:
Returns the newFile.


Copyright © 1999-2009 Melloware Inc. All Rights Reserved.