Index
All Classes and Interfaces|All Packages
A
- accept(T) - Method in interface com.github.sviperll.result4j.ExceptionfulConsumer
- accept(T, U) - Method in interface com.github.sviperll.result4j.ExceptionfulBiConsumer
- AdaptingCatcher<S,
D> - Class in com.github.sviperll.result4j -
Allows to adapt exception-throwing methods to return
Result
-type instead. - AdaptingCatcher.ForBiConsumers<S,
D> - Class in com.github.sviperll.result4j -
Specialized version of
AdaptingCatcher
that deals with methods that correspond to a shape ofBiConsumer
functional interface. - AdaptingCatcher.ForBiFunctions<S,
D> - Class in com.github.sviperll.result4j -
Specialized version of
AdaptingCatcher
that deals with methods that correspond to a shape ofBiFunction
functional interface. - AdaptingCatcher.ForConsumers<S,
D> - Class in com.github.sviperll.result4j -
Specialized version of
AdaptingCatcher
that deals with methods that correspond to a shape ofConsumer
functional interface. - AdaptingCatcher.ForFunctions<S,
D> - Class in com.github.sviperll.result4j -
Specialized version of
AdaptingCatcher
that deals with methods that correspond to a shape ofFunction
functional interface. - AdaptingCatcher.ForRunnables<S,
D> - Class in com.github.sviperll.result4j -
Specialized version of
AdaptingCatcher
that deals with methods that correspond to a shape ofRunnable
functional interface. - AdaptingCatcher.ForSuppliers<S,
D> - Class in com.github.sviperll.result4j -
Specialized version of
AdaptingCatcher
that deals with methods that correspond to a shape ofSupplier
functional interface. - andThen(ExceptionfulFunction<? super R, ? extends S, ? extends E>) - Method in interface com.github.sviperll.result4j.ExceptionfulFunction
- andThen(Result<U, E>) - Method in interface com.github.sviperll.result4j.Result
-
Combines this result with another one.
- andThen(Result<U, E>) - Method in record class com.github.sviperll.result4j.Result.Error
- andThen(Result<U, E>) - Method in record class com.github.sviperll.result4j.Result.Success
- apply(T) - Method in interface com.github.sviperll.result4j.ExceptionfulFunction
- apply(T, U) - Method in interface com.github.sviperll.result4j.ExceptionfulBiFunction
C
- Catcher<E> - Class in com.github.sviperll.result4j
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - Catcher.ForBiConsumers<E> - Class in com.github.sviperll.result4j
-
Specialized version of
Catcher
that deals with methods that correspond to a shape ofBiConsumer
functional interface. - Catcher.ForBiFunctions<E> - Class in com.github.sviperll.result4j
-
Specialized version of
Catcher
that deals with methods that correspond to a shape ofBiFunction
functional interface. - Catcher.ForConsumers<E> - Class in com.github.sviperll.result4j
- Catcher.ForFunctions<E> - Class in com.github.sviperll.result4j
- Catcher.ForRunnables<E> - Class in com.github.sviperll.result4j
- Catcher.ForSuppliers<E> - Class in com.github.sviperll.result4j
- catching(ExceptionfulBiConsumer<? super T, ? super U, ? extends S>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForBiConsumers
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - catching(ExceptionfulBiFunction<? super T, ? super U, ? extends R, ? extends S>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForBiFunctions
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - catching(ExceptionfulConsumer<? super T, ? extends S>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForConsumers
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - catching(ExceptionfulFunction<? super T, ? extends R, ? extends S>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForFunctions
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - catching(ExceptionfulRunnable<? extends S>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForRunnables
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - catching(ExceptionfulSupplier<? extends T, ? extends S>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForSuppliers
-
Allows to adapt exception-throwing methods to return
Result
-type instead. - com.github.sviperll.result4j - module com.github.sviperll.result4j
-
The module provides the definition of the Result-type similar to Result-type in Rust that allows to return either successful result or otherwise some kind of error.
- com.github.sviperll.result4j - package com.github.sviperll.result4j
-
The package provides
Result
-type similar to Result-type in Rust that allows to return either successful result or otherwise some kind of error. - compose(ExceptionfulFunction<? super U, ? extends T, ? extends E>) - Method in interface com.github.sviperll.result4j.ExceptionfulFunction
D
- discardError() - Method in interface com.github.sviperll.result4j.Result
-
Produces optional-value, that is present when this is a successful result.
- discardError() - Method in record class com.github.sviperll.result4j.Result.Error
- discardError() - Method in record class com.github.sviperll.result4j.Result.Success
E
- equals(Object) - Method in record class com.github.sviperll.result4j.Result.Error
-
Indicates whether some other object is "equal to" this one.
- equals(Object) - Method in record class com.github.sviperll.result4j.Result.Success
-
Indicates whether some other object is "equal to" this one.
- error() - Method in record class com.github.sviperll.result4j.Result.Error
-
Returns the value of the
error
record component. - error(E) - Static method in interface com.github.sviperll.result4j.Result
-
Produces
Result
-value containing given error value. - Error(E) - Constructor for record class com.github.sviperll.result4j.Result.Error
-
Creates an instance of a
Error
record class. - errorMapping(Function<? super E1, ? extends E2>) - Static method in interface com.github.sviperll.result4j.Result
-
Produces function-object that transforms error-values of results.
- ExceptionfulBiConsumer<T,
U, - Interface in com.github.sviperll.result4jE> -
Like
BiConsumer
, but throws checked exception. - ExceptionfulBiFunction<T,
U, - Interface in com.github.sviperll.result4jR, E> -
Like
BiFunction
, but throws checked exception. - ExceptionfulConsumer<T,
E> - Interface in com.github.sviperll.result4j -
Like
Consumer
, but throws checked exception. - ExceptionfulFunction<T,
R, - Interface in com.github.sviperll.result4jE> -
Like
Function
, but throws checked exception. - ExceptionfulRunnable<E> - Interface in com.github.sviperll.result4j
-
Like
Runnable
, but throws checked exception. - ExceptionfulSupplier<R,
E> - Interface in com.github.sviperll.result4j -
Like
Supplier
, but throws checked exception.
F
- flatMap(Function<? super R, ? extends Result<U, E>>) - Method in interface com.github.sviperll.result4j.Result
-
Transforms a value of this result, when this is a successful result.
- flatMapping(Function<? super T, ? extends Result<R, E>>) - Static method in interface com.github.sviperll.result4j.Result
-
Produces function-object that transforms values of successful results.
- forBiConsumers() - Method in class com.github.sviperll.result4j.AdaptingCatcher
-
Specializes
AdaptingCatcher
to deal with methods that correspond to a shape ofBiConsumer
functional interface. - forBiConsumers() - Method in class com.github.sviperll.result4j.Catcher
-
Specializes
Catcher
to deal with methods that correspond to a shape ofBiConsumer
functional interface. - forBiFunctions() - Method in class com.github.sviperll.result4j.AdaptingCatcher
-
Specializes
AdaptingCatcher
to deal with methods that correspond to a shape ofBiFunction
functional interface. - forBiFunctions() - Method in class com.github.sviperll.result4j.Catcher
-
Specializes
Catcher
to deal with methods that correspond to a shape ofBiFunction
functional interface. - forConsumers() - Method in class com.github.sviperll.result4j.AdaptingCatcher
-
Specializes
AdaptingCatcher
to deal with methods that correspond to a shape ofConsumer
functional interface. - forConsumers() - Method in class com.github.sviperll.result4j.Catcher
- forFunctions() - Method in class com.github.sviperll.result4j.AdaptingCatcher
-
Specializes
AdaptingCatcher
to deal with methods that correspond to a shape ofFunction
functional interface. - forFunctions() - Method in class com.github.sviperll.result4j.Catcher
- forRunnables() - Method in class com.github.sviperll.result4j.AdaptingCatcher
-
Specializes
AdaptingCatcher
to deal with methods that correspond to a shape ofRunnable
functional interface. - forRunnables() - Method in class com.github.sviperll.result4j.Catcher
- forSuppliers() - Method in class com.github.sviperll.result4j.AdaptingCatcher
-
Specializes
AdaptingCatcher
to deal with methods that correspond to a shape ofSupplier
functional interface. - forSuppliers() - Method in class com.github.sviperll.result4j.Catcher
- fromOptional(Optional<R>, E) - Static method in interface com.github.sviperll.result4j.Result
-
Produces
Result
-value fromOptional
value. - fromOptionalResult(Optional<Result<R, E>>) - Static method in interface com.github.sviperll.result4j.Result
-
Produces
Result
-value withOptional
successful result value.
G
- get() - Method in interface com.github.sviperll.result4j.ExceptionfulSupplier
H
- hashCode() - Method in record class com.github.sviperll.result4j.Result.Error
-
Returns a hash code value for this object.
- hashCode() - Method in record class com.github.sviperll.result4j.Result.Success
-
Returns a hash code value for this object.
I
- ifSuccess(Consumer<R>) - Method in record class com.github.sviperll.result4j.Result.Error
- ifSuccess(Consumer<R>) - Method in interface com.github.sviperll.result4j.Result
-
Invokes given consumer for a successful result value.
- ifSuccess(Consumer<R>) - Method in record class com.github.sviperll.result4j.Result.Success
- isError() - Method in record class com.github.sviperll.result4j.Result.Error
- isError() - Method in interface com.github.sviperll.result4j.Result
-
Checks that this value is an error.
- isError() - Method in record class com.github.sviperll.result4j.Result.Success
M
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForBiConsumers
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForBiFunctions
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForConsumers
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForFunctions
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForRunnables
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher.ForSuppliers
- map(Function<? super D, ? extends E>) - Method in class com.github.sviperll.result4j.AdaptingCatcher
- map(Function<? super R, ? extends U>) - Method in record class com.github.sviperll.result4j.Result.Error
- map(Function<? super R, ? extends U>) - Method in interface com.github.sviperll.result4j.Result
-
Transforms a value of this result, when this is a successful result.
- map(Function<? super R, ? extends U>) - Method in record class com.github.sviperll.result4j.Result.Success
- mapError(Function<? super E, ? extends E1>) - Method in record class com.github.sviperll.result4j.Result.Error
- mapError(Function<? super E, ? extends E1>) - Method in interface com.github.sviperll.result4j.Result
-
Transforms an error-value of this result, when this is an error.
- mapError(Function<? super E, ? extends E1>) - Method in record class com.github.sviperll.result4j.Result.Success
- mapping(Function<? super T, ? extends R>) - Static method in interface com.github.sviperll.result4j.Result
-
Produces function-object that transforms values of successful results.
O
- of(Class<E>) - Static method in class com.github.sviperll.result4j.Catcher
R
- recoverError(Function<? super E, ? extends R>) - Method in record class com.github.sviperll.result4j.Result.Error
- recoverError(Function<? super E, ? extends R>) - Method in interface com.github.sviperll.result4j.Result
-
Recovers from error and produces the value of the successful result.
- recoverError(Function<? super E, ? extends R>) - Method in record class com.github.sviperll.result4j.Result.Success
- result() - Method in record class com.github.sviperll.result4j.Result.Success
-
Returns the value of the
result
record component. - Result<R,
E> - Interface in com.github.sviperll.result4j -
A result that is either a successful execution with the value or a failure with the error-value.
- Result.Error<R,
E> - Record Class in com.github.sviperll.result4j - Result.Success<R,
E> - Record Class in com.github.sviperll.result4j - ResultCollectors - Class in com.github.sviperll.result4j
- run() - Method in interface com.github.sviperll.result4j.ExceptionfulRunnable
S
- success(R) - Static method in interface com.github.sviperll.result4j.Result
-
Produces
Result
-value containing given successful result value. - Success(R) - Constructor for record class com.github.sviperll.result4j.Result.Success
-
Creates an instance of a
Success
record class.
T
- throwError(Function<? super E, X>) - Method in interface com.github.sviperll.result4j.Result
-
Throws an exception, by converting error-value to an exception instance.
- toSingleResult(Collector<? super T, ?, R>) - Static method in class com.github.sviperll.result4j.ResultCollectors
- toString() - Method in record class com.github.sviperll.result4j.Result.Error
-
Returns a string representation of this record class.
- toString() - Method in record class com.github.sviperll.result4j.Result.Success
-
Returns a string representation of this record class.
All Classes and Interfaces|All Packages