/** * Static initializer of the Pair class. * @param left left element. * @param right right element. * @param <A> Type of the left element. * @param <B> Type of the right element. * @return the newly created Pair. */ public static <A, B> Pair<A, B> of(final A left, final B right) { return new Pair<>(left, right); } }
/** * Static initializer of the Pair class. * @param left left element. * @param right right element. * @param <A> Type of the left element. * @param <B> Type of the right element. * @return the newly created Pair. */ public static <A, B> Pair<A, B> of(final A left, final B right) { return new Pair<>(left, right); } }