public static < T , U , E extends Exception > BiConsumer < T , U > sneaked ( SneakyBiConsumer < T , U , E > biConsumer ) { return ( t , u ) -> { @ SuppressWarnings ( "unchecked" ) SneakyBiConsumer < T , U , RuntimeException > castedBiConsumer = ( SneakyBiConsumer < T , U , RuntimeException > ) biConsumer ; castedBiConsumer . accept ( t , u ) ; } ; }
Sneaky throws a BiConsumer lambda .