t

akka.stream.javadsl

SourceQueue

trait SourceQueue[T] extends AnyRef

This trait allows to have a queue as a data source for some stream.

Source
Queue.scala
Linear Supertypes
Known Subclasses
Type Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. SourceQueue
  2. AnyRef
  3. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Abstract Value Members

  1. abstract def offer(elem: T): CompletionStage[QueueOfferResult]

    Offers an element to a stream and returns a CompletionStage that: - completes with Enqueued if the element is consumed by a stream - completes with Dropped when the stream dropped the offered element - completes with QueueClosed when the stream is completed whilst the CompletionStage is active - completes with Failure(f) in case of failure to enqueue element from upstream - fails when stream is already completed

    Offers an element to a stream and returns a CompletionStage that: - completes with Enqueued if the element is consumed by a stream - completes with Dropped when the stream dropped the offered element - completes with QueueClosed when the stream is completed whilst the CompletionStage is active - completes with Failure(f) in case of failure to enqueue element from upstream - fails when stream is already completed

    Additionally when using the backpressure overflowStrategy: - If the buffer is full the CompletionStage won't be completed until there is space in the buffer - Calling offer before the CompletionStage is completed, in this case it will return a failed CompletionStage

    elem

    element to send to a stream

  2. abstract def watchCompletion(): CompletionStage[Done]

    Returns a CompletionStage that will be completed if this operator completes, or will be failed when the stream is failed.