|
|
@ -25,6 +25,7 @@ import org.springframework.boot.configurationsample.NestedConfigurationProperty;
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Demonstrate that only relevant generics are stored in the metadata.
|
|
|
|
* Demonstrate that only relevant generics are stored in the metadata.
|
|
|
|
*
|
|
|
|
*
|
|
|
|
|
|
|
|
* @param <T> the type of the config
|
|
|
|
* @author Stephane Nicoll
|
|
|
|
* @author Stephane Nicoll
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
@ConfigurationProperties("generic")
|
|
|
|
@ConfigurationProperties("generic")
|
|
|
@ -43,11 +44,9 @@ public class GenericConfig<T> {
|
|
|
|
@NestedConfigurationProperty
|
|
|
|
@NestedConfigurationProperty
|
|
|
|
private final Bar<String> bar = new Bar<String>();
|
|
|
|
private final Bar<String> bar = new Bar<String>();
|
|
|
|
|
|
|
|
|
|
|
|
private final Map<String, Bar<Integer>> stringToBar =
|
|
|
|
private final Map<String, Bar<Integer>> stringToBar = new HashMap<String, Bar<Integer>>();
|
|
|
|
new HashMap<String, Bar<Integer>>();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private final Map<String, Integer> stringToInteger =
|
|
|
|
private final Map<String, Integer> stringToInteger = new HashMap<String, Integer>();
|
|
|
|
new HashMap<String, Integer>();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public String getName() {
|
|
|
|
public String getName() {
|
|
|
|
return this.name;
|
|
|
|
return this.name;
|
|
|
|