| SourceOperationsPrefixAndTailTOut, TMat Method |
Takes up to
n elements from the stream and returns a pair containing a strict sequence of the taken element
and a stream representing the remaining elements. If
n is zero or negative, then this will return a pair
of an empty collection and a stream containing the whole upstream unchanged.
Emits when the configured number of prefix elements are available. Emits this prefix, and the rest
as a substream
Backpressures when downstream backpressures or substream backpressures
Completes when prefix elements has been consumed and substream has been consumed
Cancels when downstream cancels or substream cancels
Namespace:
Akka.Streams.Dsl
Assembly:
Akka.Streams (in Akka.Streams.dll) Version: 1.2.3.42 (1.2.3.42)
Syntax public static Source<Tuple<IImmutableList<TOut>, Source<TOut, NotUsed>>, TMat> PrefixAndTail<TOut, TMat>(
this Source<TOut, TMat> flow,
int n
)
[<ExtensionAttribute>]
static member PrefixAndTail :
flow : Source<'TOut, 'TMat> *
n : int -> Source<Tuple<IImmutableList<'TOut>, Source<'TOut, NotUsed>>, 'TMat>
Parameters
- flow
- Type: Akka.Streams.DslSourceTOut, TMat
TBD - n
- Type: SystemInt32
TBD
Type Parameters
- TOut
- TBD
- TMat
- TBD
Return Value
Type:
SourceTupleIImmutableListTOut,
SourceTOut,
NotUsed,
TMatTBD
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
SourceTOut,
TMat. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also