public Object invoke()

in core/src/main/java/org/apache/commons/proxy2/stub/AnnotationBuilder.java [64:81]


        public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
        {
            if (ProxyUtils.isHashCode(method))
            {
                return Integer.valueOf(AnnotationUtils.hashCode((Annotation) proxy));
            }
            if (ProxyUtils.isEqualsMethod(method))
            {
                return Boolean.valueOf(args[0] instanceof Annotation
                        && AnnotationUtils.equals((Annotation) proxy, (Annotation) args[0]));
            }
            if ("toString".equals(method.getName()) && method.getParameterTypes().length == 0)
            {
                return AnnotationUtils.toString((Annotation) proxy);
            }
            final ReflectionInvocation invocation = new ReflectionInvocation(provider.getObject(), method, args);
            return methodInterceptor.intercept(invocation);
        }