// Path: a-foundation/src/main/java/com/ajjpj/afoundation/function/AFunction0.java
// public interface AFunction0<R, E extends Throwable> extends Serializable {
//     R apply() throws E;
// }
// 
// Path: a-foundation/src/main/java/com/ajjpj/afoundation/function/AStatement0.java
// public interface AStatement0<E extends Throwable> extends Serializable {
//     void apply() throws E;
// }


import com.ajjpj.afoundation.function.AFunction0;
import com.ajjpj.afoundation.function.AStatement0;
package com.ajjpj.afoundation.util;




/**
 * This class throws an arbitrary exception without requiring it to be declared in a throws clause
 *
 * @author arno
 */
public class AUnchecker {
    public static void throwUnchecked(Throwable th) {
        AUnchecker.<RuntimeException> doIt(th);
    }

    @SuppressWarnings("unchecked")
    private static <T extends Throwable> void doIt(Throwable th) throws T {
        throw (T) th;
    }

    @SuppressWarnings("unused")
// Path: a-foundation/src/main/java/com/ajjpj/afoundation/function/AFunction0.java
// public interface AFunction0<R, E extends Throwable> extends Serializable {
//     R apply() throws E;
// }
// 
// Path: a-foundation/src/main/java/com/ajjpj/afoundation/function/AStatement0.java
// public interface AStatement0<E extends Throwable> extends Serializable {
//     void apply() throws E;
// }


// Path: a-foundation/src/main/java/com/ajjpj/afoundation/util/AUnchecker.java
import com.ajjpj.afoundation.function.AFunction0;
import com.ajjpj.afoundation.function.AStatement0;

package com.ajjpj.afoundation.util;




/**
 * This class throws an arbitrary exception without requiring it to be declared in a throws clause
 *
 * @author arno
 */
public class AUnchecker {
    public static void throwUnchecked(Throwable th) {
        AUnchecker.<RuntimeException> doIt(th);
    }

    @SuppressWarnings("unchecked")
    private static <T extends Throwable> void doIt(Throwable th) throws T {
        throw (T) th;
    }

    @SuppressWarnings("unused")
    public static void executeUnchecked(AStatement0<? extends Throwable> callback) {