ca.uhn.cache.internal.util
Class TimestampUtils

java.lang.Object
  extended byca.uhn.cache.internal.util.TimestampUtils

public final class TimestampUtils
extends java.lang.Object

Group utility to handle converions between java.util.Date and java.sql.TimeStamp.

Version:
$Revision: 1.1 $ updated on $Date: 2005/01/24 22:53:24 $ by $Author: bryan_tripp $
Author:
Alexei Guevara

Method Summary
static java.sql.Timestamp dateToTimestamp(java.util.Date theDate)
          Converts a date to a time stamp.
static java.util.Date timestampToDate(java.sql.Timestamp theTimestamp)
          Converts a time stamp to a date.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

dateToTimestamp

public static final java.sql.Timestamp dateToTimestamp(java.util.Date theDate)
Converts a date to a time stamp.

Parameters:
theDate - The source date.
Returns:
The corresponding time stamp.
See Also:
Timestamp

timestampToDate

public static final java.util.Date timestampToDate(java.sql.Timestamp theTimestamp)
Converts a time stamp to a date.

Parameters:
theTimestamp - The source time stamp.
Returns:
The corresponding date.
See Also:
Timestamp


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