- java.lang.Object
-
- io.smallrye.mutiny.groups.MultiItemCombination
-
public class MultiItemCombination extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description MultiItemCombination()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MultiItemCombineIterablestreams(java.lang.Iterable<? extends java.util.concurrent.Flow.Publisher<?>> iterable)Combines the items from multiple streams.<T1,T2>
MultiItemCombine2<T1,T2>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b)Combines the items from 2 streams.<T1,T2,T3>
MultiItemCombine3<T1,T2,T3>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c)Combines the items from 3 streams.<T1,T2,T3,T4>
MultiItemCombine4<T1,T2,T3,T4>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d)Combines the items from 4 streams.<T1,T2,T3,T4,T5>
MultiItemCombine5<T1,T2,T3,T4,T5>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e)Combines the items from 5 streams.<T1,T2,T3,T4,T5,T6>
MultiItemCombine6<T1,T2,T3,T4,T5,T6>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f)Combines the items from 6 streams.<T1,T2,T3,T4,T5,T6,T7>
MultiItemCombine7<T1,T2,T3,T4,T5,T6,T7>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f, java.util.concurrent.Flow.Publisher<? extends T7> g)Combines the items from 7 streams.<T1,T2,T3,T4,T5,T6,T7,T8>
MultiItemCombine8<T1,T2,T3,T4,T5,T6,T7,T8>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f, java.util.concurrent.Flow.Publisher<? extends T7> g, java.util.concurrent.Flow.Publisher<? extends T8> h)Combines the items from 8 streams.<T1,T2,T3,T4,T5,T6,T7,T8,T9>
MultiItemCombine9<T1,T2,T3,T4,T5,T6,T7,T8,T9>streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f, java.util.concurrent.Flow.Publisher<? extends T7> g, java.util.concurrent.Flow.Publisher<? extends T8> h, java.util.concurrent.Flow.Publisher<? extends T9> i)Combines the items from 9 streams.
-
-
-
Method Detail
-
streams
@CheckReturnValue public <T1,T2> MultiItemCombine2<T1,T2> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b)
Combines the items from 2 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3> MultiItemCombine3<T1,T2,T3> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c)
Combines the items from 3 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3,T4> MultiItemCombine4<T1,T2,T3,T4> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d)
Combines the items from 4 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third streamT4- the type of item from the fourth stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benulld- the fourth stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3,T4,T5> MultiItemCombine5<T1,T2,T3,T4,T5> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e)
Combines the items from 5 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third streamT4- the type of item from the fourth streamT5- the type of item from the fifth stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benulld- the fourth stream, must not benulle- the fifth stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3,T4,T5,T6> MultiItemCombine6<T1,T2,T3,T4,T5,T6> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f)
Combines the items from 6 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third streamT4- the type of item from the fourth streamT5- the type of item from the fifth streamT6- the type of item from the sixth stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benulld- the fourth stream, must not benulle- the fifth stream, must not benullf- the sixth stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3,T4,T5,T6,T7> MultiItemCombine7<T1,T2,T3,T4,T5,T6,T7> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f, java.util.concurrent.Flow.Publisher<? extends T7> g)
Combines the items from 7 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third streamT4- the type of item from the fourth streamT5- the type of item from the fifth streamT6- the type of item from the sixth streamT7- the type of item from the seventh stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benulld- the fourth stream, must not benulle- the fifth stream, must not benullf- the sixth stream, must not benullg- the seventh stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3,T4,T5,T6,T7,T8> MultiItemCombine8<T1,T2,T3,T4,T5,T6,T7,T8> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f, java.util.concurrent.Flow.Publisher<? extends T7> g, java.util.concurrent.Flow.Publisher<? extends T8> h)
Combines the items from 8 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third streamT4- the type of item from the fourth streamT5- the type of item from the fifth streamT6- the type of item from the sixth streamT7- the type of item from the seventh streamT8- the type of item from the eighth stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benulld- the fourth stream, must not benulle- the fifth stream, must not benullf- the sixth stream, must not benullg- the seventh stream, must not benullh- the eighth stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public <T1,T2,T3,T4,T5,T6,T7,T8,T9> MultiItemCombine9<T1,T2,T3,T4,T5,T6,T7,T8,T9> streams(java.util.concurrent.Flow.Publisher<? extends T1> a, java.util.concurrent.Flow.Publisher<? extends T2> b, java.util.concurrent.Flow.Publisher<? extends T3> c, java.util.concurrent.Flow.Publisher<? extends T4> d, java.util.concurrent.Flow.Publisher<? extends T5> e, java.util.concurrent.Flow.Publisher<? extends T6> f, java.util.concurrent.Flow.Publisher<? extends T7> g, java.util.concurrent.Flow.Publisher<? extends T8> h, java.util.concurrent.Flow.Publisher<? extends T9> i)
Combines the items from 9 streams.- Type Parameters:
T1- the type of item from the first streamT2- the type of item from the second streamT3- the type of item from the third streamT4- the type of item from the fourth streamT5- the type of item from the fifth streamT6- the type of item from the sixth streamT7- the type of item from the seventh streamT8- the type of item from the eighth streamT9- the type of item from the ninth stream- Parameters:
a- the first stream, must not benullb- the second stream, must not benullc- the third stream, must not benulld- the fourth stream, must not benulle- the fifth stream, must not benullf- the sixth stream, must not benullg- the seventh stream, must not benullh- the eighth stream, must not benulli- the ninth stream, must not benull- Returns:
- the object to configure the combination process
-
streams
@CheckReturnValue public MultiItemCombineIterable streams(java.lang.Iterable<? extends java.util.concurrent.Flow.Publisher<?>> iterable)
Combines the items from multiple streams.If you pass no
publishers, the resultingMultiemits the completion event immediately after subscription. If you pass a singlepublisher, it calls the combination logic for every item from this stream (wrapped in a list of a single element). The resultingMultiemits the result from that combination logic. If you pass multiplepublishers, it calls the combination logic for every group of items (1 per upstreampublisher) wrapped in a list. The resultingMultiemits the result of that combination logic.As soon as one of the
publishercompletes, the combination completes and the completion event is emitted. If any of thepublisheremits a failure, the failure is passed downstream and the combination stops.- Parameters:
iterable- the iterable containing the streams to combine. Must not benull- Returns:
- the object to configure the combination process
-
-