diff --git a/spring-boot/src/main/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcher.java b/spring-boot/src/main/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcher.java index a18b188813..f05d451ec3 100644 --- a/spring-boot/src/main/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcher.java +++ b/spring-boot/src/main/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcher.java @@ -79,7 +79,7 @@ class DefaultPropertyNamePatternsMatcher implements PropertyNamePatternsMatcher } else { char charAfter = propertyNameChars[this.names[nameIndex].length()]; - if (isDelimeter(charAfter)) { + if (isDelimiter(charAfter)) { match[nameIndex] = true; noneMatched = false; } @@ -105,7 +105,7 @@ class DefaultPropertyNamePatternsMatcher implements PropertyNamePatternsMatcher return c1 == c2; } - private boolean isDelimeter(char c) { + private boolean isDelimiter(char c) { for (char delimiter : this.delimiters) { if (c == delimiter) { return true; diff --git a/spring-boot/src/main/java/org/springframework/boot/bind/PropertiesConfigurationFactory.java b/spring-boot/src/main/java/org/springframework/boot/bind/PropertiesConfigurationFactory.java index b9582f62ec..52baf22242 100644 --- a/spring-boot/src/main/java/org/springframework/boot/bind/PropertiesConfigurationFactory.java +++ b/spring-boot/src/main/java/org/springframework/boot/bind/PropertiesConfigurationFactory.java @@ -53,9 +53,9 @@ import org.springframework.validation.Validator; public class PropertiesConfigurationFactory implements FactoryBean, MessageSourceAware, InitializingBean { - private static final char[] EXACT_DELIMETERS = { '_', '.', '[' }; + private static final char[] EXACT_DELIMITERS = { '_', '.', '[' }; - private static final char[] TARGET_NAME_DELIMETERS = { '_', '.' }; + private static final char[] TARGET_NAME_DELIMITERS = { '_', '.' }; private final Log logger = LogFactory.getLog(getClass()); @@ -308,13 +308,13 @@ public class PropertiesConfigurationFactory implements FactoryBean, if (this.ignoreUnknownFields && !isMapTarget()) { // Since unknown fields are ignored we can filter them out early to save // unnecessary calls to the PropertySource. - return new DefaultPropertyNamePatternsMatcher(EXACT_DELIMETERS, true, names); + return new DefaultPropertyNamePatternsMatcher(EXACT_DELIMITERS, true, names); } if (this.targetName != null) { // We can filter properties to those starting with the target name, but // we can't do a complete filter since we need to trigger the // unknown fields check - return new DefaultPropertyNamePatternsMatcher(TARGET_NAME_DELIMETERS, + return new DefaultPropertyNamePatternsMatcher(TARGET_NAME_DELIMITERS, this.targetName); } // Not ideal, we basically can't filter anything diff --git a/spring-boot/src/main/java/org/springframework/boot/bind/PropertySourcesPropertyValues.java b/spring-boot/src/main/java/org/springframework/boot/bind/PropertySourcesPropertyValues.java index 6d88c62fa4..cd817f29ab 100644 --- a/spring-boot/src/main/java/org/springframework/boot/bind/PropertySourcesPropertyValues.java +++ b/spring-boot/src/main/java/org/springframework/boot/bind/PropertySourcesPropertyValues.java @@ -62,7 +62,7 @@ public class PropertySourcesPropertyValues implements PropertyValues { * @param propertySources a PropertySources instance * @param includePatterns property name patterns to include from system properties and * environment variables - * @param propertyNames the property names to used in lieu of an + * @param propertyNames the property names to use in lieu of an * {@link EnumerablePropertySource}. */ public PropertySourcesPropertyValues(PropertySources propertySources, @@ -74,7 +74,7 @@ public class PropertySourcesPropertyValues implements PropertyValues { /** * Create a new PropertyValues from the given PropertySources * @param propertySources a PropertySources instance - * @param propertyNames the property names to used in lieu of an + * @param propertyNames the property names to use in lieu of an * {@link EnumerablePropertySource}. * @param includes the property name patterns to include */ diff --git a/spring-boot/src/test/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcherTests.java b/spring-boot/src/test/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcherTests.java index 6247e483f6..ed273d5d8c 100644 --- a/spring-boot/src/test/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcherTests.java +++ b/spring-boot/src/test/java/org/springframework/boot/bind/DefaultPropertyNamePatternsMatcherTests.java @@ -69,9 +69,9 @@ public class DefaultPropertyNamePatternsMatcherTests { @Test public void withSquareBrackets() throws Exception { - char[] delimeters = "._[".toCharArray(); + char[] delimiters = "._[".toCharArray(); PropertyNamePatternsMatcher matcher = new DefaultPropertyNamePatternsMatcher( - delimeters, "aaa", "bbbb", "ccccc"); + delimiters, "aaa", "bbbb", "ccccc"); assertTrue(matcher.matches("bbbb")); assertTrue(matcher.matches("bbbb[4]")); assertFalse(matcher.matches("bbb[4]"));