Package fj
Class Try
java.lang.Object
fj.Try
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <A,
E extends Exception>
P1<Validation<E, A>> Promotes the Try0 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, E extends Exception>
F<A, Validation<E, B>> Promotes the Try1 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, E extends Exception>
F2<A, B, Validation<E, C>> Promotes the Try2 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, D, E extends Exception>
F3<A, B, C, Validation<E, D>> Promotes the Try3 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, D, E, Z extends Exception>
F4<A, B, C, D, Validation<Z, E>> Promotes the Try4 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, D, E, F, Z extends Exception>
F5<A, B, C, D, E, Validation<Z, F>> Promotes the Try5 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, D, E, F, G, Z extends Exception>
F6<A, B, C, D, E, F, Validation<Z, G>> Promotes the Try6 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, D, E, F, G, H, Z extends Exception>
F7<A, B, C, D, E, F, G, Validation<Z, H>> Promotes the Try7 to a Validation that returns an Exception on the failure side and its result on the success side.static <A,
B, C, D, E, F, G, H, I, Z extends Exception>
F8<A, B, C, D, E, F, G, H, Validation<Z, I>> Promotes the Try8 to a Validation that returns an Exception on the failure side and its result on the success side.static <A> IO
<A> io
(Try0<A, ? extends IOException> t)
-
Constructor Details
-
Try
private Try()
-
-
Method Details
-
f
Promotes the Try0 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try0 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
Promotes the Try1 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try1 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
Promotes the Try2 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try2 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
Promotes the Try3 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try3 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
public static <A,B, F4<A,C, D, E, Z extends Exception> B, fC, D, Validation<Z, E>> (Try4<A, B, C, D, E, Z> t) Promotes the Try4 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try4 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
public static <A,B, F5<A,C, D, E, F, Z extends Exception> B, fC, D, E, Validation<Z, F>> (Try5<A, B, C, D, E, F, Z> t) Promotes the Try5 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try5 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
public static <A,B, F6<A,C, D, E, F, G, Z extends Exception> B, fC, D, E, F, Validation<Z, G>> (Try6<A, B, C, D, E, F, G, Z> t) Promotes the Try6 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try6 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
public static <A,B, F7<A,C, D, E, F, G, H, Z extends Exception> B, fC, D, E, F, G, Validation<Z, H>> (Try7<A, B, C, D, E, F, G, H, Z> t) Promotes the Try7 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try7 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
f
public static <A,B, F8<A,C, D, E, F, G, H, I, Z extends Exception> B, fC, D, E, F, G, H, Validation<Z, I>> (Try8<A, B, C, D, E, F, G, H, I, Z> t) Promotes the Try8 to a Validation that returns an Exception on the failure side and its result on the success side.- Parameters:
t
- A Try8 to promote- Returns:
- A Validation with an Exception on the failure side and its result on the success side.
-
io
-