SunTimes documentation

com.web_tomorrow.utils.suntimes
Class Time

java.lang.Object
  |
  +--com.web_tomorrow.utils.suntimes.Time

public class Time
extends java.lang.Object

Java class for representing a time as a simple triple of numbers (hours, minutes, seconds). This class is used by the SunTimes class to return sunrise and sunset times, where the meanings of the hours and minutes are well defined. This class obviates the need to use the JDK Date and Calendar classes, which do all sorts of locale-specific corrections. This class can be initialized from a pair of values, or a single value which is taken to mean a number of hours with a fraction. In the latter case it will normalize it to the range 0:00:00 to 23:59:59. (c)2001 Kevin Boone/Web-Tomorrow, all rights reserved


Field Summary
protected  int hour
           
protected  int minute
           
protected  int second
           
 
Constructor Summary
Time(double _hour)
           
Time(int _hour, int _minute, int _second)
           
 
Method Summary
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

hour

protected int hour

minute

protected int minute

second

protected int second
Constructor Detail

Time

public Time(int _hour,
            int _minute,
            int _second)

Time

public Time(double _hour)
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

(c)2001 Kevin Boone/Web-Tomorrow