upTo

fun <T : Comparable<*>> upTo(endpoint: T, boundType: BoundType): Range<T>

Creates a Range of the form (-∞, endpoint) or (-∞, endpoint] depending on the boundType.

Return

created Range

Parameters

endpoint

upper endpoint

boundType

type of bound which must not be BoundType.NONE