Package com.blazebit.cdi.exception.annotation

Examples of com.blazebit.cdi.exception.annotation.ExceptionWrapping


    /*
     * Retrieve the exceptions declared in the throws clause of the
     * intercepted method
     */
    Class<?>[] declaredExceptions = m.getExceptionTypes();
    ExceptionWrapping wrappingAnnotation = AnnotationUtils.findAnnotation(
        m, targetClass, ExceptionWrapping.class);
    ExceptionWrap[] wraps = null;
    Object ret;
    boolean doWrapping = true;

    if (wrappingAnnotation == null) {
      throw new IllegalStateException(
          "The interceptor annotation can not be determined!");
    }

    wraps = wrappingAnnotation.value();

    /* Only try to do wrapping when exceptionWrap elements are available */
    doWrapping = wraps != null && wraps.length > 0;

    try {
View Full Code Here


    Class<?> targetClass = targetObject == null ? m.getDeclaringClass()
        : targetObject.getClass();
    // Retrieve the exceptions declared in the throws clause of the
    // intercepted method
    Class<?>[] declaredExceptions = m.getExceptionTypes();
    ExceptionWrapping wrappingAnnotation = AnnotationUtil.findAnnotation(m,
        targetClass, ExceptionWrapping.class);
    ExceptionWrap[] wraps = null;
    Object ret;
    boolean doWrapping = true;

    if (wrappingAnnotation == null) {
      throw new IllegalStateException(
          "The interceptor annotation can not be determined!");
    }

    wraps = wrappingAnnotation.value();

    // Only try to do wrapping when exceptionWrap elements are available
    doWrapping = wraps != null && wraps.length > 0;

    try {
View Full Code Here

TOP

Related Classes of com.blazebit.cdi.exception.annotation.ExceptionWrapping

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.