class EqualsInterceptor {

	@RuntimeType
	public static Object intercept(@This Object thiz, @Argument(0) Object other, @FieldValue("bean") Object bean) throws IllegalAccessException, NoSuchFieldException {			
        if (thiz == other) {
            return true;
        } else if (other instanceof EnhancedProxy) {
            return bean.equals(ReflectionUtils.getValue(other, "bean"));
        } else {
        	return bean.equals(other);
        }
	}

	private  EqualsInterceptor();

}