Object nested = checkNested(properties, method.getReturnType(), propertyPath);
if (nested != null) {
propertyMapping.put(method, nested);
} else if (value != null) {
propertyMapping.put(method, getCoercer().coerce(value, method.getReturnType()));
} else if (property.optional()) {
propertyMapping.put(method, getCoercer().coerce(property.value(), method.getReturnType()));
} else {
throw new ConfigurationException(Messages.getString("required.property.0.is.missing", propertyPath));
}
}