equalsEpsilon

fun equalsEpsilon(left: TimeInterval? = definedExternally, right: TimeInterval? = definedExternally, epsilon: Double? = definedExternally, dataComparer: DataComparer? = definedExternally): Boolean(source)

Compares two instances and returns true if they are within epsilon seconds of each other. That is, in order for the dates to be considered equal (and for this function to return true), the absolute value of the difference between them, in seconds, must be less than epsilon.

Return

true if the two dates are within epsilon seconds of each other; otherwise false.

Parameters

left

The first instance.

right

The second instance.

epsilon

The maximum number of seconds that should separate the two instances. Default value - 0

dataComparer

A function which compares the data of the two intervals. If omitted, reference equality is used.

See also