Documentation / dataflow-async / com.femastudios.dataflow.async.extensions / coerceAtMost
Go to reference

coerceAtMost

fun Attribute<Byte>.coerceAtMost(maximumValue: Attribute<Byte>): Attribute<Byte>
fun Attribute<Byte>.coerceAtMost(maximumValue: Byte): Attribute<Byte>
fun <T : Comparable<T>> Attribute<T>.coerceAtMost(maximumValue: T): Attribute<T>
fun <T : Comparable<T>> Attribute<T>.coerceAtMost(maximumValue: Attribute<T>): Attribute<T>
fun Attribute<Double>.coerceAtMost(maximumValue: Attribute<Double>): Attribute<Double>
fun Attribute<Double>.coerceAtMost(maximumValue: Double): Attribute<Double>
fun Attribute<Float>.coerceAtMost(maximumValue: Attribute<Float>): Attribute<Float>
fun Attribute<Float>.coerceAtMost(maximumValue: Float): Attribute<Float>
fun Attribute<Int>.coerceAtMost(maximumValue: Attribute<Int>): Attribute<Int>
fun Attribute<Int>.coerceAtMost(maximumValue: Int): Attribute<Int>
fun Attribute<Long>.coerceAtMost(maximumValue: Attribute<Long>): Attribute<Long>
fun Attribute<Long>.coerceAtMost(maximumValue: Long): Attribute<Long>
fun Attribute<Short>.coerceAtMost(maximumValue: Attribute<Short>): Attribute<Short>
fun Attribute<Short>.coerceAtMost(maximumValue: Short): Attribute<Short>

Same as coerceAtMost, but accepts Attribute and returns a new Attribute.

Calling this function is equivalent to use transform and calling coerceAtMost in the transformation function.

This is simply a convenience function.

See Also

kotlin.ranges.coerceAtMost


fun <T : Comparable<T>> T.coerceAtMost(maximumValue: Attribute<T>): Attribute<T>

Same as coerceAtMost, but accepts Attribute and returns a new Attribute.

Calling this function is equivalent to use transform and calling coerceAtMost in the transformation function.

This is simply a convenience function.

See Also

kotlin.ranges.coerceAtMost