
ru.hnau.jutils.producer.extensions.int.producerExtensionsIntWithByte.kt Maven / Gradle / Ivy
The newest version!
package ru.hnau.jutils.producer.extensions.int
import ru.hnau.jutils.producer.Producer
operator fun Producer.plus(other: Byte) = map { it + other }
operator fun Producer.minus(other: Byte) = map { it - other }
operator fun Producer.times(other: Byte) = map { it * other }
operator fun Producer.div(other: Byte) = map { it / other }
operator fun Producer.rem(other: Byte) = map { it % other }
operator fun Producer.plus(other: Producer) = combineWith(other, Int::plus)
operator fun Producer.minus(other: Producer) = combineWith(other, Int::minus)
operator fun Producer.times(other: Producer) = combineWith(other, Int::times)
operator fun Producer.div(other: Producer) = combineWith(other, Int::div)
operator fun Producer.rem(other: Producer) = combineWith(other, Int::rem)
© 2015 - 2025 Weber Informatics LLC | Privacy Policy