Skip to content

Commit

Permalink
Cleanup the operator classes package layout
Browse files Browse the repository at this point in the history
UniSerializedSubscriber is tied to AbstractUni#subscribing so it can't be moved right now.

Also RevApi doesn't seem to honor package exclusion, so it complains that classes have been removed.
  • Loading branch information
jponge committed Jan 20, 2021
1 parent d41996d commit f0efbc0
Show file tree
Hide file tree
Showing 77 changed files with 165 additions and 92 deletions.
4 changes: 2 additions & 2 deletions implementation/revapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"filter" : {
"packages" : {
"regex" : true,
"include" : [ "io\\.smallrye\\.mutiny\\..*", "io\\.smallrye\\.mutiny\\.*" ],
"exclude" : [ "io\\.smallrye\\.mutiny\\.operators\\.*", "io\\.smallrye\\.mutiny\\.operators\\..*" ]
"include" : [ "io\\.smallrye\\.mutiny(\\..+)?" ],
"exclude" : [ "io\\.smallrye\\.mutiny\\.operators(\\..+)?" ]
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.MultiBroadcaster;
import io.smallrye.mutiny.operators.multi.MultiBroadcaster;

/**
* Makes the upstream {@link Multi} be able to broadcast its events ({@code items}, {@code failure}, and
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.MultiSwitchOnEmpty;
import io.smallrye.mutiny.operators.multi.MultiSwitchOnEmpty;
import io.smallrye.mutiny.subscription.MultiEmitter;

public class MultiIfEmpty<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import org.reactivestreams.Publisher;

import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.operators.*;

public class MultiItemCombination {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;
import static io.smallrye.mutiny.helpers.ParameterValidation.size;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.groups;

import static io.smallrye.mutiny.helpers.ParameterValidation.nonNull;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

import io.smallrye.mutiny.CompositeException;
import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.operators.MultiCombine;
import io.smallrye.mutiny.operators.multi.MultiCombine;

/**
* Creates new {@link Multi} by merging several {@link Multi} or {@link Publisher}.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.MultiSwitchOnCompletion;
import io.smallrye.mutiny.operators.multi.MultiOnCompletionCall;
import io.smallrye.mutiny.operators.multi.MultiOnCompletionInvoke;
import io.smallrye.mutiny.operators.multi.MultiSwitchOnCompletion;
import io.smallrye.mutiny.subscription.MultiEmitter;

public class MultiOnCompletion<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.MultiFlatMapOnFailure;
import io.smallrye.mutiny.operators.MultiOnFailureTransform;
import io.smallrye.mutiny.operators.multi.MultiFlatMapOnFailure;
import io.smallrye.mutiny.operators.multi.MultiOnFailureInvoke;
import io.smallrye.mutiny.operators.multi.MultiOnFailureTransform;
import io.smallrye.mutiny.subscription.Cancellable;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniAndCombination;
import io.smallrye.mutiny.operators.uni.UniAndCombination;

public class UniAndGroupIterable<T1> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOrCombination;
import io.smallrye.mutiny.operators.uni.UniOrCombination;

public class UniAny {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import io.smallrye.mutiny.TimeoutException;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.operators.UniBlockingAwait;
import io.smallrye.mutiny.operators.uni.UniBlockingAwait;

/**
* Waits and returns the item emitted by the {@link Uni}. If the {@link Uni} receives a failure, the failure is thrown.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import io.smallrye.mutiny.TimeoutException;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.operators.UniBlockingAwait;
import io.smallrye.mutiny.operators.uni.UniBlockingAwait;

/**
* Likes {@link UniAwait} but wrapping the item event into an {@link Optional}. This optional is empty if the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import io.smallrye.mutiny.converters.UniConverter;
import io.smallrye.mutiny.helpers.ParameterValidation;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.*;
import io.smallrye.mutiny.operators.uni.UniNever;
import io.smallrye.mutiny.operators.uni.builders.*;
import io.smallrye.mutiny.subscription.UniEmitter;
import io.smallrye.mutiny.subscription.UniSubscriber;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.AbstractUni;
import io.smallrye.mutiny.operators.UniMemoizeOp;
import io.smallrye.mutiny.operators.uni.UniMemoizeOp;

@Experimental("Memoization is an experimental feature at this stage")
public class UniMemoize<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.helpers.ParameterValidation;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOnCancellation;
import io.smallrye.mutiny.operators.UniOnCancellationCall;
import io.smallrye.mutiny.operators.uni.UniOnCancellation;
import io.smallrye.mutiny.operators.uni.UniOnCancellationCall;

public class UniOnCancel<T> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
import io.smallrye.mutiny.CompositeException;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOnFailureFlatMap;
import io.smallrye.mutiny.operators.UniOnFailureTransform;
import io.smallrye.mutiny.operators.UniOnItemConsume;
import io.smallrye.mutiny.operators.uni.UniOnFailureFlatMap;
import io.smallrye.mutiny.operators.uni.UniOnFailureTransform;
import io.smallrye.mutiny.operators.uni.UniOnItemConsume;

/**
* Configures the failure handler.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOnItemConsume;
import io.smallrye.mutiny.operators.UniOnItemTransform;
import io.smallrye.mutiny.operators.UniOnItemTransformToMulti;
import io.smallrye.mutiny.operators.UniOnItemTransformToUni;
import io.smallrye.mutiny.operators.uni.UniOnItemConsume;
import io.smallrye.mutiny.operators.uni.UniOnItemTransform;
import io.smallrye.mutiny.operators.uni.UniOnItemTransformToMulti;
import io.smallrye.mutiny.operators.uni.UniOnItemTransformToUni;
import io.smallrye.mutiny.subscription.UniEmitter;

public class UniOnItem<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniDelayOnItem;
import io.smallrye.mutiny.operators.UniDelayUntil;
import io.smallrye.mutiny.operators.uni.UniDelayOnItem;
import io.smallrye.mutiny.operators.uni.UniDelayUntil;

/**
* Configures the delay applied to the item emission.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
import io.smallrye.mutiny.CompositeException;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOnItemOrFailureConsume;
import io.smallrye.mutiny.operators.UniOnItemOrFailureFlatMap;
import io.smallrye.mutiny.operators.UniOnItemOrFailureMap;
import io.smallrye.mutiny.operators.uni.UniOnItemOrFailureConsume;
import io.smallrye.mutiny.operators.uni.UniOnItemOrFailureFlatMap;
import io.smallrye.mutiny.operators.uni.UniOnItemOrFailureMap;
import io.smallrye.mutiny.subscription.UniEmitter;
import io.smallrye.mutiny.tuples.Functions;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOnSubscribeCall;
import io.smallrye.mutiny.operators.UniOnSubscribeInvoke;
import io.smallrye.mutiny.operators.uni.UniOnSubscribeCall;
import io.smallrye.mutiny.operators.uni.UniOnSubscribeInvoke;
import io.smallrye.mutiny.subscription.UniSubscription;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOnTermination;
import io.smallrye.mutiny.operators.UniOnTerminationCall;
import io.smallrye.mutiny.operators.uni.UniOnTermination;
import io.smallrye.mutiny.operators.uni.UniOnTerminationCall;
import io.smallrye.mutiny.tuples.Functions;

public class UniOnTerminate<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import io.smallrye.mutiny.TimeoutException;
import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniFailOnTimeout;
import io.smallrye.mutiny.operators.uni.UniFailOnTimeout;

public class UniOnTimeout<T> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

import io.smallrye.mutiny.Uni;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniOrCombination;
import io.smallrye.mutiny.operators.uni.UniOrCombination;

public class UniOr<T> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import io.smallrye.mutiny.helpers.ExponentialBackoff;
import io.smallrye.mutiny.helpers.ParameterValidation;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.UniRetryAtMost;
import io.smallrye.mutiny.operators.uni.UniRetryAtMost;

// TODO This method should be renamed to UniOnFailureRetry, however it's a breaking change.
public class UniRetry<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.AbstractUni;
import io.smallrye.mutiny.operators.UniSerializedSubscriber;
import io.smallrye.mutiny.operators.UniSubscribeToCompletionStage;
import io.smallrye.mutiny.operators.uni.UniSubscribeToCompletionStage;
import io.smallrye.mutiny.subscription.Cancellable;
import io.smallrye.mutiny.subscription.UniSubscriber;
import io.smallrye.mutiny.subscription.UniSubscription;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
import io.smallrye.mutiny.groups.*;
import io.smallrye.mutiny.helpers.ParameterValidation;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.uni.UniEmitOn;
import io.smallrye.mutiny.operators.uni.UniMemoizeOp;
import io.smallrye.mutiny.operators.uni.UniRunSubscribeOn;
import io.smallrye.mutiny.subscription.UniSubscriber;
import io.smallrye.mutiny.tuples.Tuple2;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.operators.multi;

import java.time.Duration;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.operators.multi;

import java.util.List;
import java.util.function.Function;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.operators.multi;

import static io.smallrye.mutiny.helpers.ParameterValidation.MAPPER_RETURNED_NULL;

Expand All @@ -11,7 +11,7 @@

import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.multi.MultiOnFailureResumeOp;
import io.smallrye.mutiny.operators.MultiOperator;

public class MultiFlatMapOnFailure<T> extends MultiOperator<T, T> {
private final Predicate<? super Throwable> predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ boolean isDoneOrCancelled(boolean d, boolean empty, Queue<?> q) {
}
}

static final class GroupedUnicast<K, T> extends AbstractMulti<T> implements GroupedMulti<K, T> {
public static final class GroupedUnicast<K, T> extends AbstractMulti<T> implements GroupedMulti<K, T> {

private final State<T, K> downstream;
private final K key;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.operators.multi;

import static io.smallrye.mutiny.helpers.ParameterValidation.MAPPER_RETURNED_NULL;

Expand All @@ -11,7 +11,7 @@

import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.multi.MultiOnFailureResumeOp;
import io.smallrye.mutiny.operators.MultiOperator;

public class MultiOnFailureTransform<T> extends MultiOperator<T, T> {
private final Predicate<? super Throwable> predicate;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.operators.multi;

import static io.smallrye.mutiny.helpers.ParameterValidation.SUPPLIER_PRODUCED_NULL;

Expand All @@ -9,7 +9,7 @@

import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.multi.MultiConcatOp;
import io.smallrye.mutiny.operators.MultiOperator;

public class MultiSwitchOnCompletion<T> extends MultiOperator<T, T> {
private final Supplier<Publisher<? extends T>> supplier;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.smallrye.mutiny.operators;
package io.smallrye.mutiny.operators.multi;

import static io.smallrye.mutiny.helpers.ParameterValidation.SUPPLIER_PRODUCED_NULL;

Expand All @@ -9,7 +9,7 @@

import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.infrastructure.Infrastructure;
import io.smallrye.mutiny.operators.multi.MultiSwitchOnEmptyOp;
import io.smallrye.mutiny.operators.MultiOperator;
import io.smallrye.mutiny.operators.multi.builders.FailedMulti;

public class MultiSwitchOnEmpty<T> extends MultiOperator<T, T> {
Expand Down
Loading

0 comments on commit f0efbc0

Please sign in to comment.