private static boolean memberEquals(final Class<?> type,final Object o1,final Object o2){
  if (o1 == o2) {
    return true;
  }
  if (o1 == null || o2 == null) {
    return false;
  }
  if (type.isArray()) {
    return arrayMemberEquals(type.getComponentType(),o1,o2);
  }
  if (type.isAnnotation()) {
    return equals((Annotation)o1,(Annotation)o2);
  }
  return o1.equals(o2);
}

private static boolean memberEquals ( final Class < ? > type , final Object o1 , final Object o2 ) { if ( o1 == o2 ) { return true ; } if ( o1 == null || o2 == null ) { return false ; } if ( type . isArray ( ) ) { return arrayMemberEquals ( type . getComponentType ( ) , o1 , o2 ) ; } if ( type . isAnnotation ( ) ) { return equals ( ( Annotation ) o1 , ( Annotation ) o2 ) ; } return o1 . equals ( o2 ) ; }
helper method for checking whether two objects of the given type are equal . this method is used to compare the parameters of two annotation instances .
