public int hashCode() {
        if (cachedHashCode == Integer.MIN_VALUE) {
            int hashCode = 0;

            // Load the annotation class
            getAnnotationType();

            Method[] methods = annotationType.getDeclaredMethods();
            for (int i = 0; i < methods.length; ++ i) {
                String name = methods[i].getName();
                int valueHashCode = 0;

                // Get the value
                MemberValue mv = annotation.getMemberValue(name);
                Object value = null;
                try {
                   if (mv != null)
                       value = mv.getValue(classLoader, pool, methods[i]);
                   if (value == null)
                       value = getDefault(name, methods[i]);
                }
                catch (RuntimeException e) {
                    throw e;
                }
                catch (Exception e) {
                    throw new RuntimeException("Error retrieving value " + name + " for annotation " + annotation.getTypeName(), e);
                }

                // Calculate the hash code
                if (value != null) {
                    if (value.getClass().isArray())
                        valueHashCode = arrayHashCode(value);
                    else
                        valueHashCode = value.hashCode();
                } 
                hashCode += 127 * name.hashCode() ^ valueHashCode;
            }
          
            cachedHashCode = hashCode;
        }
        return cachedHashCode;
    }