Package org.springframework.validation

# Interface DataBinder.ValueResolver

Enclosing class:
  DataBinder

public static interface DataBinder.ValueResolver
Strategy for `constructor binding` to look up the values to bind to a given constructor parameter.

## Method Summary

Modifier and Type
Method
Description
`Set<String>`
`getNames()`
Return the names of all property values.
`Object`
`resolveValue(String name, Class<?> type)`
Resolve the value for the given name and target parameter type.

## Method Details

### resolveValue

@Nullable Object resolveValue(String name, Class<?> type)
Resolve the value for the given name and target parameter type.

Parameters:
  `name` - the name to use for the lookup, possibly a nested path for constructor parameters on nested objects
  `type` - the target type, based on the constructor parameter type
Returns:
  the resolved value, possibly `null` if none found

### getNames

Set<String> getNames()
Return the names of all property values.

Useful for proactive checks whether there are property values nested further below the path for a constructor arg. If not then the constructor arg can be considered missing and not to be instantiated.

Since:
  6.1.2