org.ojalgo.type
Class CalendarDate
java.lang.Object
org.ojalgo.type.CalendarDate
- All Implemented Interfaces:
- Comparable<CalendarDate>
public final class CalendarDate
- extends Object
- implements Comparable<CalendarDate>
Corresponds to a Calendar AND a Date.
It is immutable and interacts with CalendarDateUnit.
- Author:
- apete
millis
public final long millis
CalendarDate
public CalendarDate()
CalendarDate
public CalendarDate(Calendar aCalendar)
CalendarDate
public CalendarDate(Date aDate)
CalendarDate
public CalendarDate(long timeInMillis)
CalendarDate
public CalendarDate(String anSqlString)
make
public static CalendarDate make(Calendar aCalendar,
CalendarDateUnit aResolution)
make
public static CalendarDate make(CalendarDateUnit aResolution)
make
public static CalendarDate make(Date aDate,
CalendarDateUnit aResolution)
make
public static CalendarDate make(long aTimeInMIllis,
CalendarDateUnit aResolution)
compareTo
public int compareTo(CalendarDate ref)
- Specified by:
compareTo in interface Comparable<CalendarDate>
equals
public boolean equals(Object obj)
- Overrides:
equals in class Object
filter
public CalendarDate filter(CalendarDateUnit aResolution)
getCalendar
public Calendar getCalendar()
getCalendar
public Calendar getCalendar(Locale aLocale)
getCalendar
public Calendar getCalendar(TimeZone aTimeZone)
getCalendar
public Calendar getCalendar(TimeZone aTimeZone,
Locale aLocale)
getDate
public Date getDate()
hashCode
public int hashCode()
- Overrides:
hashCode in class Object
step
public CalendarDate step(CalendarDateUnit aStepUnit)
step
public CalendarDate step(int aStepCount,
CalendarDateUnit aStepUnit)
toSqlDate
public Date toSqlDate()
toSqlTime
public Time toSqlTime()
toSqlTimestamp
public Timestamp toSqlTimestamp()
toString
public String toString()
- Overrides:
toString in class Object
toTimeInMillis
public long toTimeInMillis(CalendarDateUnit aResolution)