Package com.mojang.datafixers.optics
Class Optics
java.lang.Object
com.mojang.datafixers.optics.Optics
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic <S,
T, A, B> Adapter<S, T, A, B> static <S,
T, A, B> Affine<S, T, A, B> affine
(Function<S, Either<T, A>> preview, BiFunction<B, S, T> build) eitherAffine
(Affine<F, F2, A, B> fAffine, Affine<G, G2, A, B> gAffine) eitherLens
(Lens<F, F2, A, B> fLens, Lens<G, G2, A, B> gLens) eitherTraversal
(Traversal<F, F2, A, B> fOptic, Traversal<G, G2, A, B> gOptic) static <R,
A, B> Forget<R, A, B> static <R,
A, B> com.mojang.datafixers.optics.ForgetE<R, A, B> static <R,
A, B> ForgetOpt<R, A, B> static <A,
B> Function<A, B> getFunc
(App2<FunctionType.Mu, A, B> box) static <S,
T, A, B> com.mojang.datafixers.optics.Getter<S, T, A, B> static <S,
T, A, B> com.mojang.datafixers.optics.Grate<S, T, A, B> grate
(FunctionType<FunctionType<FunctionType<S, A>, B>, T> grate) static <S,
T> Adapter<S, T, S, T> id()
static <F,
G, F2> Inj1<F, G, F2> inj1()
static <F,
G, G2> Inj2<F, G, G2> inj2()
static boolean
static boolean
static boolean
static boolean
static boolean
static <S,
T, A, B> Lens<S, T, A, B> lens
(Function<S, A> view, BiFunction<B, S, T> update) static <A,
B> ListTraversal<A, B> static <S,
T, A, B> Prism<S, T, A, B> static <F,
G, F2> Proj1<F, G, F2> proj1()
static <F,
G, G2> Proj2<F, G, G2> proj2()
static <I,
J, X> com.mojang.datafixers.optics.PStore<I, J, X> static <R,
A, B> com.mojang.datafixers.optics.ReForget<R, A, B> static <R,
A, B> ReForgetC<R, A, B> reForgetC
(String name, Either<Function<R, B>, BiFunction<A, R, B>> either) static <R,
A, B> com.mojang.datafixers.optics.ReForgetE<R, A, B> static <R,
A, B> com.mojang.datafixers.optics.ReForgetEP<R, A, B> reForgetEP
(String name, Function<Either<A, Pair<A, R>>, B> function) static <R,
A, B> com.mojang.datafixers.optics.ReForgetP<R, A, B> reForgetP
(String name, BiFunction<A, R, B> function) static <S,
T, A, B> Adapter<S, T, A, B> toAdapter
(Optic<? super Profunctor.Mu, S, T, A, B> optic) static <S,
T, A, B> Affine<S, T, A, B> toAffine
(Optic<? super AffineP.Mu, S, T, A, B> optic) static <S,
T, A, B> com.mojang.datafixers.optics.Getter<S, T, A, B> toGetter
(Optic<? super GetterP.Mu, S, T, A, B> optic) static <S,
T, A, B> Lens<S, T, A, B> toLens
(Optic<? super Cartesian.Mu, S, T, A, B> optic) static <S,
T, A, B> Prism<S, T, A, B> toPrism
(Optic<? super Cocartesian.Mu, S, T, A, B> optic) static <S,
T, A, B> Traversal<S, T, A, B> toTraversal
(Optic<? super TraversalP.Mu, S, T, A, B> optic)
-
Constructor Details
-
Optics
public Optics()
-
-
Method Details
-
toAdapter
-
toLens
-
toPrism
-
toAffine
-
toGetter
public static <S,T, com.mojang.datafixers.optics.Getter<S,A, B> T, toGetterA, B> (Optic<? super GetterP.Mu, S, T, A, B> optic) -
toTraversal
public static <S,T, Traversal<S,A, B> T, toTraversalA, B> (Optic<? super TraversalP.Mu, S, T, A, B> optic) -
id
-
isId
-
adapter
-
lens
-
prism
-
affine
public static <S,T, Affine<S,A, B> T, affineA, B> (Function<S, Either<T, A>> preview, BiFunction<B, S, T> build) -
getter
-
forget
-
forgetOpt
-
forgetE
-
reForget
public static <R,A, com.mojang.datafixers.optics.ReForget<R,B> A, reForgetB> (Function<R, B> function) -
grate
public static <S,T, com.mojang.datafixers.optics.Grate<S,A, B> T, grateA, B> (FunctionType<FunctionType<FunctionType<S, A>, B>, T> grate) -
reForgetEP
-
reForgetE
-
reForgetP
public static <R,A, com.mojang.datafixers.optics.ReForgetP<R,B> A, reForgetPB> (String name, BiFunction<A, R, B> function) -
reForgetC
public static <R,A, ReForgetC<R,B> A, reForgetCB> (String name, Either<Function<R, B>, BiFunction<A, R, B>> either) -
pStore
-
getFunc
-
proj1
-
isProj1
-
proj2
-
isProj2
-
inj1
-
isInj1
-
inj2
-
isInj2
-
eitherLens
-
eitherAffine
-
eitherTraversal
-
listTraversal
-