ScalaDateAdapter

class Object
trait Matchable
class Any

Value members

Concrete fields

val add: (Double, Double, String) => Double

Adds the specified amount of unit to the given timestamp.

Adds the specified amount of unit to the given timestamp.

Value Params
{Unit}

unit - the unit as string

{number}

amount - the amount to add

Returns

{number}

val diff: (Double, Double, String) => Double

Returns the number of unit between the given timestamps.

Returns the number of unit between the given timestamps.

Value Params
{Unit}

unit - the unit as string

{number}

b - the timestamp to subtract

Returns

{number}

val endOf: (Double, String) => Double

Returns end of unit for the given timestamp.

Returns end of unit for the given timestamp.

Value Params
{Unit|'isoWeek'}

unit - the unit as string

{number}

timestamp - the input timestamp

Returns

{number}

val format: (Double, String) => String

Returns the formatted date in the specified format for a given timestamp.

Returns the formatted date in the specified format for a given timestamp.

Value Params
{number}

timestamp - the timestamp to format

{string}

format - the date/time token

Returns

{string}

val formats: () => Dynamic

Returns a map of time formats for the supported formatting units defined in Unit as well as 'datetime' representing a detailed date/time string.

Returns a map of time formats for the supported formatting units defined in Unit as well as 'datetime' representing a detailed date/time string.

Returns

{{string: string}}

val parse: (Any, Option[Any]) => Double

TODO Parses the given value and return the associated timestamp.

TODO Parses the given value and return the associated timestamp.

Value Params
{any}

value - the value to parse (usually comes from the data)

{string}

[format] - the expected data format

val startOf: (Double, String, Any) => Double

Returns start of unit for the given timestamp.

Returns start of unit for the given timestamp.

Value Params
{Unit|'isoWeek'}

unit - the unit as string

{number}

[weekday] - the ISO day of the week with 1 being Monday and 7 being Sunday (only needed if param unit is isoWeek).

Returns

{number}