abstract class DateTime extends AnyRef
Immutable, fast and efficient Date + Time implementation without any dependencies. Does not support TimeZones, all DateTime values are always GMT based. Note that this implementation discards milliseconds (i.e. rounds down to full seconds).
- Source
- DateTime.java
- Alphabetic
- By Inheritance
- DateTime
- AnyRef
- Any
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- All
Instance Constructors
- new DateTime()
Abstract Value Members
-
abstract
def
clicks(): Long
Returns this instant as "clicks", i.e.
Returns this instant as "clicks", i.e. as milliseconds since January 1, 1970, 00:00:00 GMT
-
abstract
def
day(): Int
Returns the day of this instant in GMT.
-
abstract
def
hour(): Int
Returns the hour of this instant in GMT.
-
abstract
def
isLeapYear(): Boolean
Returns if this instant interpreted as a Date in GMT belongs to a leap year.
-
abstract
def
minus(millis: Long): DateTime
Creates a new
DateTime
that represents the point in time the given number of ms earlier. -
abstract
def
minute(): Int
Returns the minute of this instant in GMT.
-
abstract
def
month(): Int
Returns the month of this instant in GMT.
-
abstract
def
monthStr(): String
Returns the month as a 3 letter abbreviation:
Jan
,Feb
,Mar
,Apr
,May
,Jun
,Jul
,Aug
,Sep
,Oct
,Nov
orDec
-
abstract
def
plus(millis: Long): DateTime
Creates a new
DateTime
that represents the point in time the given number of ms later. -
abstract
def
second(): Int
Returns the second of this instant in GMT.
-
abstract
def
toIsoDateString(): String
Returns a String representation like this:
yyyy-mm-dd
-
abstract
def
toIsoDateTimeString(): String
Returns a String representation like this:
yyyy-mm-ddThh:mm:ss
-
abstract
def
toIsoLikeDateTimeString(): String
Returns a String representation like this:
yyyy-mm-dd hh:mm:ss
-
abstract
def
toRfc1123DateTimeString(): String
Returns an RFC1123 date string, e.g.
Returns an RFC1123 date string, e.g.
Sun, 06 Nov 1994 08:49:37 GMT
-
abstract
def
weekday(): Int
Returns the weekday of this instant in GMT.
Returns the weekday of this instant in GMT. Sunday is 0, Monday is 1, etc.
-
abstract
def
weekdayStr(): String
Returns the day of the week as a 3 letter abbreviation:
Sun
,Mon
,Tue
,Wed
,Thu
,Fri
orSat
-
abstract
def
year(): Int
Returns the year of this instant in GMT.
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
- def +(other: String): String
- def ->[B](y: B): (DateTime, B)
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- def ensuring(cond: (DateTime) ⇒ Boolean, msg: ⇒ Any): DateTime
- def ensuring(cond: (DateTime) ⇒ Boolean): DateTime
- def ensuring(cond: Boolean, msg: ⇒ Any): DateTime
- def ensuring(cond: Boolean): DateTime
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
- def formatted(fmtstr: String): String
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- def →[B](y: B): (DateTime, B)