DateTime.compare

GCompareFunc-compatible comparison for GDateTime's. Both GDateTime<-- -->'s must be non-NULL. Since 2.26

class DateTime
static
int
compare

Parameters

dt1 DateTime

first GDateTime to compare

dt2 DateTime

second GDateTime to compare

Return Value

Type: int

-1, 0 or 1 if dt1 is less than, equal to or greater than dt2.

Meta