boolean (@NotNull Accessor accessor, @NotNull Object bean, @Nullable Object beanValue) { if (beanValue == null) { return false; } ThreeState accepts = accepts(accessor.getName(), beanValue); if (accepts != ThreeState.UNSURE) { return accepts.toBoolean(); } if (Boolean.FALSE.equals(beanValue) || beanValue instanceof String && ((String)beanValue).isEmpty() || beanValue instanceof Collection && ((Collection<?>)beanValue).isEmpty() || beanValue instanceof Map && ((Map<?, ?>)beanValue).isEmpty()) { return false; } return true; }