public static <T0, T1> FuncN<Void> fromAction(final Action2<? super T0, ? super T1> f) {
        return new FuncN<Void>() {

            @SuppressWarnings("unchecked")
            @Override
            public Void call(Object... args) {
                if (args.length != 2) {
                    throw new RuntimeException("Action3 expecting 2 arguments.");
                }
                f.call((T0) args[0], (T1) args[1]);
                return null;
            }

        };
    }
public static < T0 , T1 > FuncN < Void > fromAction ( final Action2 < ? super T0 , ? super T1 > f ) { return new FuncN < Void > ( ) { @ SuppressWarnings ( "unchecked" ) @ Override public Void call ( Object ... args ) { if ( args . length != 2 ) { throw new RuntimeException ( "Action3 expecting 2 arguments." ) ; } f . call ( ( T0 ) args [ 0 ] , ( T1 ) args [ 1 ] ) ; return null ; } } ; }
Converts an {@link Action2} to a {@link FuncN} to allow heterogeneous handling of functions with different arities.

@param f the {@code Action2} to convert
@return a {@link FuncN} representation of {@code f}