ca.uhn.cache
Class VolatilityEnum

java.lang.Object
  extended byorg.apache.commons.lang.enum.Enum
      extended byca.uhn.cache.VolatilityEnum
All Implemented Interfaces:
java.lang.Comparable, java.io.Serializable

public class VolatilityEnum
extends org.apache.commons.lang.enum.Enum
implements java.lang.Comparable

Type safe codes for data volatility.

Version:
$Revision: 1.1 $ updated on $Date: 2005/01/24 22:52:04 $ by $Author: bryan_tripp $
Author:
Bryan Tripp
See Also:
Serialized Form

Field Summary
static VolatilityEnum STABLE
          Describes data that are unlikely to change (e.g.
static VolatilityEnum VOLATILE
          Describes data that are likely to change (e.g.
 
Fields inherited from class org.apache.commons.lang.enum.Enum
iToString
 
Constructor Summary
protected VolatilityEnum(java.lang.String theName, int theLevel)
           
 
Method Summary
 int compareTo(java.lang.Object theObject)
          Ordering from most to least volatile.
static VolatilityEnum getEnum(java.lang.String theName)
           
static java.util.List getEnumList()
           
protected  java.lang.Integer getLevel()
           
 
Methods inherited from class org.apache.commons.lang.enum.Enum
equals, getEnum, getEnumClass, getEnumList, getEnumMap, getName, hashCode, iterator, readResolve, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

STABLE

public static final VolatilityEnum STABLE
Describes data that are unlikely to change (e.g. have been labelled "final").


VOLATILE

public static final VolatilityEnum VOLATILE
Describes data that are likely to change (e.g. have been labelled "incomplete").

Constructor Detail

VolatilityEnum

protected VolatilityEnum(java.lang.String theName,
                         int theLevel)
Parameters:
theName - text code for volatility
theLevel - level of volatility, for ordering purposes (lower means more volatile)
Method Detail

getLevel

protected java.lang.Integer getLevel()
Returns:
an Integer level for ordering (lower means more volatile)

getEnum

public static VolatilityEnum getEnum(java.lang.String theName)
Parameters:
theName - name of desired VolatilityEnum
Returns:
VolatilityEnum that has the given name.

getEnumList

public static java.util.List getEnumList()
Returns:
List of all VolatilityEnum.

compareTo

public int compareTo(java.lang.Object theObject)
Ordering from most to least volatile.

Specified by:
compareTo in interface java.lang.Comparable
See Also:
Comparable.compareTo(java.lang.Object)


Copyright © 2004-2005 University Health Network. All Rights Reserved.