Rio Project 4.2 API Documentation



org.rioproject.resources.util
Class TimeUtil

java.lang.Object
  extended by org.rioproject.resources.util.TimeUtil

public class TimeUtil
extends Object

Format time into a readable string.

Author:
Dennis Reedy

Constructor Summary
TimeUtil()
           
 
Method Summary
static long computeLeaseRenewalTime(long leaseDuration)
          Compute the delay to wait for lease renewal based on lease duration
static String format(long duration)
          Format a time into a readable string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimeUtil

public TimeUtil()
Method Detail

format

public static String format(long duration)
Format a time into a readable string

Parameters:
duration - The time duration to format
Returns:
The formatted time

computeLeaseRenewalTime

public static long computeLeaseRenewalTime(long leaseDuration)
Compute the delay to wait for lease renewal based on lease duration

Parameters:
leaseDuration - How long the lease has been granted for
Returns:
How long to wait to attempt to renew the lease

Copyright © Rio Project.

Copyright © 2006-2011 Rio Project. All Rights Reserved.