chore: make code style consistent
This commit is contained in:
parent
a2cea2f33e
commit
89ec3fbf29
380 changed files with 479 additions and 936 deletions
|
|
@ -96,5 +96,4 @@ class AnnotatedMethodService<Context, Result> implements Service<Context, Result
|
|||
public int hashCode() {
|
||||
return Objects.hash(this.methodHandle);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,7 +51,6 @@ enum AnnotatedMethodServiceFactory {
|
|||
method.getName(), instance.getClass().getCanonicalName(),
|
||||
method.getParameterCount()
|
||||
));
|
||||
|
||||
}
|
||||
map.put(
|
||||
new AnnotatedMethodService<>(instance, method),
|
||||
|
|
@ -60,5 +59,4 @@ enum AnnotatedMethodServiceFactory {
|
|||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -99,5 +99,4 @@ public abstract class ChunkedRequestContext<@NonNull Context, @NonNull Result> {
|
|||
return this.requests.isEmpty();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,5 +52,4 @@ public final class PipelineException extends RuntimeException {
|
|||
public PipelineException(final @NonNull String message, final @NonNull Exception cause) {
|
||||
super(message, cause);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,5 +51,4 @@ enum ServiceFilterHandler {
|
|||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -245,5 +245,4 @@ public final class ServicePipeline {
|
|||
Executor getExecutor() {
|
||||
return this.executor;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -59,5 +59,4 @@ public final class ServicePipelineBuilder {
|
|||
this.executor = Objects.requireNonNull(executor, "Executor may not be null");
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -70,5 +70,4 @@ public final class ServicePump<Context> {
|
|||
) {
|
||||
return this.through(TypeToken.get(clazz));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -147,12 +147,10 @@ public final class ServiceRepository<Context, Response> {
|
|||
@Override
|
||||
public int compareTo(final @NonNull ServiceWrapper<T> other) {
|
||||
return Comparator.<ServiceWrapper<T>>comparingInt(
|
||||
wrapper -> wrapper.isDefaultImplementation()
|
||||
? Integer.MIN_VALUE
|
||||
: Integer.MAX_VALUE).thenComparingInt(wrapper -> wrapper.executionOrder.ordinal())
|
||||
wrapper -> wrapper.isDefaultImplementation()
|
||||
? Integer.MIN_VALUE
|
||||
: Integer.MAX_VALUE).thenComparingInt(wrapper -> wrapper.executionOrder.ordinal())
|
||||
.thenComparingInt(wrapper -> wrapper.registrationOrder).compare(this, other);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -166,5 +166,4 @@ public final class ServiceSpigot<Context, Result> {
|
|||
public @NonNull CompletableFuture<ServicePump<Result>> forwardAsynchronously() {
|
||||
return this.getResultAsynchronously().thenApply(this.pipeline::pump);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,5 +42,4 @@ public @interface Order {
|
|||
* @return Priority
|
||||
*/
|
||||
ExecutionOrder value() default ExecutionOrder.SOON;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,5 +50,4 @@ public @interface ServiceImplementation {
|
|||
* @return Service to implement
|
||||
*/
|
||||
Class<? extends Service<?, ?>> value();
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -86,7 +86,5 @@ public interface ConsumerService<Context>
|
|||
public synchronized Throwable initCause(final Throwable cause) {
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,5 +58,4 @@ public interface PartialResultService<Context, Result, Chunked extends ChunkedRe
|
|||
* @return Map of request-result pairs
|
||||
*/
|
||||
@NonNull Map<@NonNull Context, @NonNull Result> handleRequests(@NonNull List<Context> requests);
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -72,5 +72,4 @@ public interface Service<Context, Result> extends Function<@NonNull Context, @Nu
|
|||
default @Nullable ExecutionOrder order() {
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,5 +49,4 @@ public interface SideEffectService<Context> extends Service<Context, State> {
|
|||
*/
|
||||
@Override
|
||||
@NonNull State handle(@NonNull Context context) throws Exception;
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue