|
|
@ -19,6 +19,7 @@ package org.springframework.boot.context.properties.bind;
|
|
|
|
import java.util.function.Supplier;
|
|
|
|
import java.util.function.Supplier;
|
|
|
|
|
|
|
|
|
|
|
|
import org.springframework.boot.context.properties.source.ConfigurationPropertyName;
|
|
|
|
import org.springframework.boot.context.properties.source.ConfigurationPropertyName;
|
|
|
|
|
|
|
|
import org.springframework.boot.context.properties.source.ConfigurationPropertySource;
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Internal strategy used by {@link Binder} to bind aggregates (Maps, Lists, Arrays).
|
|
|
|
* Internal strategy used by {@link Binder} to bind aggregates (Maps, Lists, Arrays).
|
|
|
@ -31,16 +32,17 @@ abstract class AggregateBinder<T> {
|
|
|
|
|
|
|
|
|
|
|
|
private final BindContext context;
|
|
|
|
private final BindContext context;
|
|
|
|
|
|
|
|
|
|
|
|
private final boolean allowRecursiveBinding;
|
|
|
|
AggregateBinder(BindContext context) {
|
|
|
|
|
|
|
|
|
|
|
|
AggregateBinder(BindContext context, boolean allowRecursiveBinding) {
|
|
|
|
|
|
|
|
this.context = context;
|
|
|
|
this.context = context;
|
|
|
|
this.allowRecursiveBinding = allowRecursiveBinding;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
boolean isAllowRecursiveBinding() {
|
|
|
|
/**
|
|
|
|
return this.allowRecursiveBinding;
|
|
|
|
* Determine if recursive binding is supported.
|
|
|
|
}
|
|
|
|
* @param source the configuration property source or {@code null} for all sources.
|
|
|
|
|
|
|
|
* @return if recursive binding is supported
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
protected abstract boolean isAllowRecursiveBinding(
|
|
|
|
|
|
|
|
ConfigurationPropertySource source);
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Perform binding for the aggregate.
|
|
|
|
* Perform binding for the aggregate.
|
|
|
|