public class WikibaseDate extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
WikibaseDate.ToStringFormat
Format for toString.
|
| Constructor and Description |
|---|
WikibaseDate(long year,
int month,
int day,
int hour,
int minute,
int second)
Build using explicit date parts.
|
| Modifier and Type | Method and Description |
|---|---|
WikibaseDate |
cleanWeirdStuff()
Wikidata contains some odd dates like -13798000000-00-00T00:00:00Z and
February 30th.
|
int |
day()
Day component of the date.
|
boolean |
equals(Object obj) |
static WikibaseDate |
fromSecondsSinceEpoch(long secondsSinceEpoch)
Build a WikibaseDate from seconds since epoch.
|
static WikibaseDate |
fromString(String string)
Build a WikibaseDate from the string representation.
|
int |
hashCode() |
int |
hour()
Hour component of the date.
|
int |
minute()
Minute component of the date.
|
int |
month()
Month component of the date.
|
int |
second()
Second component of the date.
|
long |
secondsSinceEpoch()
Convert this date into a number of seconds since epoch.
|
String |
toString() |
String |
toString(WikibaseDate.ToStringFormat format)
Build a WikibaseDate from the string representation.
|
long |
year()
Year component of the date.
|
public WikibaseDate(long year,
int month,
int day,
int hour,
int minute,
int second)
public static WikibaseDate fromString(String string)
public static WikibaseDate fromSecondsSinceEpoch(long secondsSinceEpoch)
public WikibaseDate cleanWeirdStuff()
public long secondsSinceEpoch()
public String toString(WikibaseDate.ToStringFormat format)
public long year()
public int month()
public int day()
public int hour()
public int minute()
public int second()
Copyright © 2015. All rights reserved.