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

akka.stream.CompletionStrategy.scala Maven / Gradle / Ivy

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

package akka.stream

import akka.annotation.{ DoNotInherit, InternalApi }

@DoNotInherit
sealed trait CompletionStrategy

case object CompletionStrategy {

  /**
   * INTERNAL API
   */
  @InternalApi
  private[akka] case object Immediately extends CompletionStrategy

  /**
   * INTERNAL API
   */
  @InternalApi
  private[akka] case object Draining extends CompletionStrategy

  /**
   * The completion will be signaled immediately even if elements are still buffered.
   */
  def immediately: CompletionStrategy = Immediately

  /**
   * Already buffered elements will be signaled before signaling completion.
   */
  def draining: CompletionStrategy = Draining
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy