@Test public void iso() { assertAll( () -> assertEquals(tuple, pointToTuple.get(point)), () -> assertEquals(point, pointToTuple.set(tuple)), () -> assertEquals(tuple, tupleToPoint.set(point)), () -> assertEquals(point, tupleToPoint.get(tuple)), () -> assertEquals(tuple, tupleToPoint.reverse().reverse().set(point)), () -> assertEquals(point, tupleToPoint.reverse().reverse().get(tuple)), () -> assertEquals(point, pointToPoint.set(point)), () -> assertEquals(point, pointToPoint.get(point)), () -> assertEquals(point, identity.set(point)), () -> assertEquals(point, identity.get(point)), () -> assertEquals(new Point(2, 4), pointToTuple.modify(point, t -> t.map(x -> x + 1, y -> y * 2))) ); }
protected Iso(PIso<S, S, A, A> delegate) { this.delegate = checkNonNull(delegate); }
Iso { protected Iso(PIso<S, S, A, A> delegate) { this.delegate = checkNonNull(delegate); } }
Iso { protected Iso(PIso<S, S, A, A> delegate) { this.delegate = checkNonNull(delegate); } protected  Iso(PIso<S, S, A, A> delegate); }
Iso { protected Iso(PIso<S, S, A, A> delegate) { this.delegate = checkNonNull(delegate); } protected  Iso(PIso<S, S, A, A> delegate); static Iso<S, A> of(Function1<S, A> get, Function1<A, S> reverseGet); static Iso<S, S> identity(); Iso<A, S> reverse(); A get(S target); S set(A value); S modify(S target, Operator1<A> mapper); Operator1<S> lift(Operator1<A> mapper); Lens<S, A> asLens(); Prism<S, A> asPrism(); Optional<S, A> asOptional(); Iso<S, B> compose(Iso<A, B> other); Lens<S, B> compose(Lens<A, B> other); Prism<S, B> compose(Prism<A, B> other); Optional<S, B> compose(Optional<A, B> other); }
Iso { protected Iso(PIso<S, S, A, A> delegate) { this.delegate = checkNonNull(delegate); } protected  Iso(PIso<S, S, A, A> delegate); static Iso<S, A> of(Function1<S, A> get, Function1<A, S> reverseGet); static Iso<S, S> identity(); Iso<A, S> reverse(); A get(S target); S set(A value); S modify(S target, Operator1<A> mapper); Operator1<S> lift(Operator1<A> mapper); Lens<S, A> asLens(); Prism<S, A> asPrism(); Optional<S, A> asOptional(); Iso<S, B> compose(Iso<A, B> other); Lens<S, B> compose(Lens<A, B> other); Prism<S, B> compose(Prism<A, B> other); Optional<S, B> compose(Optional<A, B> other);  }