All Downloads are FREE. Search and download functionalities are using the official Maven repository.

akka.stream.javadsl.package.scala Maven / Gradle / Ivy

/*
 * Copyright (C) 2015-2020 Lightbend Inc. 
 */

package akka.stream

package object javadsl {
  def combinerToScala[M1, M2, M](f: akka.japi.function.Function2[M1, M2, M]): (M1, M2) => M =
    f match {
      case x if x eq Keep.left   => scaladsl.Keep.left.asInstanceOf[(M1, M2) => M]
      case x if x eq Keep.right  => scaladsl.Keep.right.asInstanceOf[(M1, M2) => M]
      case s: Function2[_, _, _] => s.asInstanceOf[(M1, M2) => M]
      case other                 => other.apply _
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy