gnu.math
public class DateTime extends Quantity implements Cloneable
Field Summary | |
---|---|
static int | DATE_MASK |
static int | DAY_MASK |
static TimeZone | GMT |
static int | HOURS_MASK |
static int | MINUTES_MASK |
static int | MONTH_MASK |
static int | SECONDS_MASK |
static int | TIMEZONE_MASK |
static int | TIME_MASK |
static int | YEAR_MASK |
Constructor Summary | |
---|---|
DateTime(int mask) | |
DateTime(int mask, GregorianCalendar calendar) |
Method Summary | |
---|---|
static DateTime | add(DateTime x, Duration y, int k) |
Numeric | add(Object y, int k) |
static DateTime | addMinutes(DateTime x, int y) |
Numeric | addReversed(Numeric x, int k) |
static DateTime | addSeconds(DateTime x, int y) |
DateTime | adjustTimezone(int newOffset) |
DateTime | cast(int newComponents) |
static int | compare(DateTime date1, DateTime date2) Return -1, 0, or 1, depending on which value is greater. |
int | compare(Object obj) |
int | components() |
static int | daysInMonth(int month, int year) |
int | getDay() |
int | getHours() |
int | getMinutes() |
int | getMonth() |
int | getNanoSecondsOnly() |
int | getSecondsOnly() |
int | getWholeSeconds() |
int | getYear() |
int | getZoneMinutes() |
boolean | isExact() |
static boolean | isLeapYear(int year) |
boolean | isZero() |
boolean | isZoneUnspecified() |
static TimeZone | minutesToTimeZone(int minutes) Get a TimeZone object for a given offset. |
Complex | number() |
static DateTime | parse(String value, int mask) |
void | setTimeZone(TimeZone timeZone) |
static Duration | sub(DateTime date1, DateTime date2) |
void | toString(StringBuffer sbuf) |
String | toString() |
void | toStringDate(StringBuffer sbuf) |
void | toStringTime(StringBuffer sbuf) |
void | toStringZone(StringBuffer sbuf) |
static void | toStringZone(int minutes, StringBuffer sbuf) |
Unit | unit() |
DateTime | withZoneUnspecified() |
Parameters: minutes timezone offset in minutes.