PlatformDateTime

laika.time.PlatformDateTime$
See thePlatformDateTime companion trait

Attributes

Companion
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Type members

Types

type Type = Type

The platform-dependent type representing dates.

The platform-dependent type representing dates.

Attributes

Value members

Concrete methods

def parse(dateString: String): Either[String, Type]

Parses the specified string either as a date with time zone, or a local date time, or just a date.

Parses the specified string either as a date with time zone, or a local date time, or just a date.

In case of a date time with time zone, ISO 8601 is supported (allowing either Z for UTC or +/- followed by a time offset with or without colon, e.g. +01:30 or +0130.

In case of the time zone info missing, local date time is assumed.

Examples: 2011-10-10 or 2011-10-10T14:48:00 or 2011-10-10T14:48:00+0100 are all allowed.

This is also designed to be somewhat aligned to Date.parse in JavaScript.

Attributes