Skip to content

Commit

Permalink
Fix typos in javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
cescoffier committed Dec 6, 2020
1 parent 04ee39c commit 2615d01
Show file tree
Hide file tree
Showing 13 changed files with 102 additions and 84 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Makes the upstream {@link Multi} be able to broadcast its events ({@code items}, {@code failure}, and
* {@code completion}) to multiple subscribers.
*
* Broadcast transforms the upstream into a <em>hot streams</em> meaning that late subscriber won't see all the events.
*
* @param <T> the type of item
*/
public class MultiBroadcast<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.operators.MultiCollector;

/**
* Collects / aggregates items from the upstream and send the resulting <em>collection</em> / structure when the
* upstream completes. The resulting structure is emitted through a {@link Uni}.
*
* <strong>IMPORTANT:</strong> Do not use on unbounded streams, as it would lead to {@link OutOfMemoryError}.
*
* @param <T> the type of item sent by the upstream.
*/
public class MultiCollect<T> {

private final Multi<T> upstream;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@

import io.smallrye.mutiny.Multi;

/**
* Converts the upstream into another reactive type.
*
* @param <T> the type of item emitted by the upstream.
*/
public class MultiConvert<T> {

private final Multi<T> upstream;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

import io.smallrye.mutiny.Multi;

/**
* Allows the creation of instances of {@link Multi} by merging/combining/concatenating multiple upstreams.
*/
public class MultiCreateBy {
public static final MultiCreateBy INSTANCE = new MultiCreateBy();

Expand Down Expand Up @@ -39,13 +42,13 @@ public MultiMerge merging() {
* <p>
* The resulting {@link Multi} can:
* <ul>
* <li>collects an item of every observed streams and combine them. If one of the observed stream sends the
* <li>collects an item of every observed streams and combines them. If one of the observed stream sends the
* completion event, the event is propagated in the produced stream, and no other combination are emitted.</li>
* <li>as soon as on of the observed stream emits an item, it combine it with the latest items for the other stream.
* <li>as soon as on of the observed stream emits an item, it combines it with the latest items emitted by other stream.
* the completion event is sent when all the observed streams have completed (with a completion event).</li>
* </ul>
* <p>
* The combination also allows to collect the failures and propagate a failure when all observed streams have completed
* The combination also allows to collect the failures and propagates a failure when all observed streams have completed
* (or failed) instead of propagating the failure immediately.
*
* @return the object to configure the combination
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,18 @@ public MultiItemCombine2<T1, T2> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine2}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine3<T1, T2, T3> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine3}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine4<T1, T2, T3, T4> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine4}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine5<T1, T2, T3, T4, T5> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine5}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine6<T1, T2, T3, T4, T5, T6> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine6}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine7<T1, T2, T3, T4, T5, T6, T7> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine7}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine8<T1, T2, T3, T4, T5, T6, T7, T8> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine8}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@ public MultiItemCombine9<T1, T2, T3, T4, T5, T6, T7, T8, T9> collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombine9}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,18 +35,18 @@ public MultiItemCombineIterable collectFailures() {
}

/**
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until
* all the observed streams emit an item and call the combination logic. In other words, it associated the items
* from different stream having the same <em>index</em>. If one of the stream completes, the produced stream also
* By default, the combination logic is called with one item of each observed stream. It <em>waits</em> until all
* the upstreams emit an item, and it invokes the combination logic. In other words, it associated the items from
* different streams having the same <em>index</em>. If one of the streams completes, the produced stream also
* completes.
*
* <p>
* With this method, you can change this behavior and call the combination logic every time one of one of the observed
* streams emit an item. It would call the combination logic with this new item and the latest items emitted by the
* other streams. It wait until all the streams have emitted at least an item before calling the combination logic.
* With this method, you can change this behavior and call the combination logic when one of the observed streams
* emits an item. It calls the combination logic with this new item and the latest items emitted by the other
* streams.
* <p>
* If one of the stream completes before having emitted a value, the produced streams also completes without emitting
* a value.
* It waits until all the streams have emitted at least one item before calling the combination logic.
* If one of the streams completes before emitting a value, the produced stream also completes without emitting an
* item.
*
* @return the current {@link MultiItemCombineIterable}
*/
Expand Down

0 comments on commit 2615d01

Please sign in to comment.