edu.stanford.rt.datatype
Class TimeType

java.lang.Object
  |
  +--edu.stanford.rt.datatype.DataType
        |
        +--edu.stanford.rt.datatype.SimpleType
              |
              +--edu.stanford.rt.datatype.OrderedType
                    |
                    +--edu.stanford.rt.datatype.TimeType

public class TimeType
extends OrderedType

Author:
Ninghui Li, Sandra Qiu
DataType for time values in RTML. It's a wrapper class for XML built-in date time type.

Field Summary
 
Fields inherited from class edu.stanford.rt.datatype.DataType
 
Constructor Summary
TimeType(java.lang.String name)
          Constructor for TimeType.
 
Method Summary
 int compares(DataValue value1, DataValue value2)
          Method compares.
 boolean isValidValue(DataValue value)
          Check if the DataValue o is a legal value for its type.
 java.lang.String toString(java.lang.String indent)
          Method toString.
 
Methods inherited from class edu.stanford.rt.datatype.DataType
getName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TimeType

public TimeType(java.lang.String name)
Constructor for TimeType.

Method Detail

isValidValue

public boolean isValidValue(DataValue value)
Description copied from class: SimpleType
Check if the DataValue o is a legal value for its type.

Specified by:
isValidValue in class SimpleType

compares

public int compares(DataValue value1,
                    DataValue value2)
Description copied from class: OrderedType
Method compares. Compares two DataValue objects.

Specified by:
compares in class OrderedType
Parameters:
value1 -
value2 -
Returns:
int

toString

public java.lang.String toString(java.lang.String indent)
Description copied from class: DataType
Method toString.

Overrides:
toString in class DataType
Parameters:
indent -
Returns:
String