Scoop API

scoop:scoop.std:0.1.0

Instant

class Instant

source · line 22
public
public class Instant private constructor(
    /**
     * Whole seconds since 1970-01-01T00:00:00Z, rounded toward negative infinity.
     */
    public val epochSeconds: Long,
    /**
     * The nonnegative fractional nanoseconds within the epoch second.
     */
    public val nanosecondsOfSecond: Int) : Equals<Instant>, Compare<Instant>, Hash, ToString, Add<Duration, Instant>, Sub<Duration, Instant>

An absolute point on the Unix timeline at nanosecond precision. The supported range corresponds to LocalDate.MIN through LocalDate.MAX in UTC.

function hash

source · line 46
public
public override fun hash(): Long

Computes a hash consistent with component equality.

function toEpochMilliseconds

source · line 67
public
public fun toEpochMilliseconds(): Long

Returns epoch milliseconds rounded toward negative infinity; overflow throws ArithmeticException.

property nanosecondsOfSecond

source · line 30
public
public val nanosecondsOfSecond: Int

get: public read-only

The nonnegative fractional nanoseconds within the epoch second.

property epochSeconds

source · line 26
public
public val epochSeconds: Long

get: public read-only

Whole seconds since 1970-01-01T00:00:00Z, rounded toward negative infinity.