// Path: app/src/main/java/com/pacoworks/dereference/reactive/tuples/Quadriple.java
// @EqualsAndHashCode
// @ToString
// public class Quadriple<T, U, V, X> implements Serializable {
//     public final T first;
// 
//     public final U second;
// 
//     public final V third;
// 
//     public final X fourth;
// 
//     public Quadriple(T first, U second, V third, X fourth) {
//         this.first = first;
//         this.second = second;
//         this.third = third;
//         this.fourth = fourth;
//     }
// }
// 
// Path: app/src/main/java/com/pacoworks/dereference/reactive/tuples/Triple.java
// @EqualsAndHashCode
// @ToString
// public class Triple<T, U, V> implements Serializable {
//     public final T first;
// 
//     public final U second;
// 
//     public final V third;
// 
//     public Triple(T first, U second, V third) {
//         this.first = first;
//         this.second = second;
//         this.third = third;
//     }
// }
// 
// Path: app/src/main/java/com/pacoworks/dereference/reactive/tuples/Tuple.java
// @EqualsAndHashCode
// @ToString
// public class Tuple<T, U> implements Serializable {
//     public final T first;
// 
//     public final U second;
// 
//     public Tuple(T first, U second) {
//         this.first = first;
//         this.second = second;
//     }
// }


import lombok.experimental.UtilityClass;
import rx.functions.Func2;
import com.pacoworks.dereference.reactive.tuples.Quadriple;
import com.pacoworks.dereference.reactive.tuples.Triple;
import com.pacoworks.dereference.reactive.tuples.Tuple;
        };
    }

    public static <T, U> Func2<T, U, Tuple<U, T>> singleToTupleInverse() {
        return new Func2<T, U, Tuple<U, T>>() {
            @Override
            public Tuple<U, T> call(T first, U second) {
                return new Tuple<>(second, first);
            }
        };
    }

    public static <T, U, V> Func2<T, Tuple<U, V>, Triple<T, U, V>> singleToTriple() {
        return new Func2<T, Tuple<U, V>, Triple<T, U, V>>() {
            @Override
            public Triple<T, U, V> call(T first, Tuple<U, V> second) {
                return new Triple<>(first, second.first, second.second);
            }
        };
    }

    public static <T, U, V> Func2<Tuple<T, U>, V, Triple<T, U, V>> tupleToTriple() {
        return new Func2<Tuple<T, U>, V, Triple<T, U, V>>() {
            @Override
            public Triple<T, U, V> call(Tuple<T, U> first, V second) {
                return new Triple<>(first.first, first.second, second);
            }
        };
    }

// Path: app/src/main/java/com/pacoworks/dereference/reactive/tuples/Quadriple.java
// @EqualsAndHashCode
// @ToString
// public class Quadriple<T, U, V, X> implements Serializable {
//     public final T first;
// 
//     public final U second;
// 
//     public final V third;
// 
//     public final X fourth;
// 
//     public Quadriple(T first, U second, V third, X fourth) {
//         this.first = first;
//         this.second = second;
//         this.third = third;
//         this.fourth = fourth;
//     }
// }
// 
// Path: app/src/main/java/com/pacoworks/dereference/reactive/tuples/Triple.java
// @EqualsAndHashCode
// @ToString
// public class Triple<T, U, V> implements Serializable {
//     public final T first;
// 
//     public final U second;
// 
//     public final V third;
// 
//     public Triple(T first, U second, V third) {
//         this.first = first;
//         this.second = second;
//         this.third = third;
//     }
// }
// 
// Path: app/src/main/java/com/pacoworks/dereference/reactive/tuples/Tuple.java
// @EqualsAndHashCode
// @ToString
// public class Tuple<T, U> implements Serializable {
//     public final T first;
// 
//     public final U second;
// 
//     public Tuple(T first, U second) {
//         this.first = first;
//         this.second = second;
//     }
// }


// Path: app/src/main/java/com/pacoworks/dereference/reactive/RxTuples.java
import lombok.experimental.UtilityClass;
import rx.functions.Func2;
import com.pacoworks.dereference.reactive.tuples.Quadriple;
import com.pacoworks.dereference.reactive.tuples.Triple;
import com.pacoworks.dereference.reactive.tuples.Tuple;

        };
    }

    public static <T, U> Func2<T, U, Tuple<U, T>> singleToTupleInverse() {
        return new Func2<T, U, Tuple<U, T>>() {
            @Override
            public Tuple<U, T> call(T first, U second) {
                return new Tuple<>(second, first);
            }
        };
    }

    public static <T, U, V> Func2<T, Tuple<U, V>, Triple<T, U, V>> singleToTriple() {
        return new Func2<T, Tuple<U, V>, Triple<T, U, V>>() {
            @Override
            public Triple<T, U, V> call(T first, Tuple<U, V> second) {
                return new Triple<>(first, second.first, second.second);
            }
        };
    }

    public static <T, U, V> Func2<Tuple<T, U>, V, Triple<T, U, V>> tupleToTriple() {
        return new Func2<Tuple<T, U>, V, Triple<T, U, V>>() {
            @Override
            public Triple<T, U, V> call(Tuple<T, U> first, V second) {
                return new Triple<>(first.first, first.second, second);
            }
        };
    }

    public static <T, U, V, X> Func2<T, Triple<U, V, X>, Quadriple<T, U, V, X>> singleToQuadruple() {