CAMEL-11718: Polished
Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/5db786a2 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/5db786a2 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/5db786a2 Branch: refs/heads/master Commit: 5db786a28b161dab922bc72aaeb173ede905412b Parents: c937ee6 Author: Claus Ibsen <[email protected]> Authored: Mon Sep 4 17:03:49 2017 +0200 Committer: Claus Ibsen <[email protected]> Committed: Mon Sep 4 17:03:49 2017 +0200 ---------------------------------------------------------------------- .../apache/camel/spring/boot/util/CamelPropertiesHelper.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/5db786a2/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/util/CamelPropertiesHelper.java ---------------------------------------------------------------------- diff --git a/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/util/CamelPropertiesHelper.java b/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/util/CamelPropertiesHelper.java index ddfb090..262b69b 100644 --- a/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/util/CamelPropertiesHelper.java +++ b/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/util/CamelPropertiesHelper.java @@ -47,12 +47,12 @@ public final class CamelPropertiesHelper { * @param context the CamelContext * @param target the target bean * @param properties the properties - * @param failOnNotSet whether to fail if an option cannot be set on the target bean. + * @param failIfNotSet whether to fail if an option either does not exists on the target bean or if the option cannot be due no suitable setter methods with the given type * @return <tt>true</tt> if at least one option was configured * @throws IllegalArgumentException is thrown if an option cannot be configured on the bean because there is no suitable setter method and failOnNoSet is true. * @throws Exception for any other kind of error */ - public static boolean setCamelProperties(CamelContext context, Object target, Map<String, Object> properties, boolean failOnNotSet) throws Exception { + public static boolean setCamelProperties(CamelContext context, Object target, Map<String, Object> properties, boolean failIfNotSet) throws Exception { ObjectHelper.notNull(context, "context"); ObjectHelper.notNull(target, "target"); ObjectHelper.notNull(properties, "properties"); @@ -83,7 +83,7 @@ public final class CamelPropertiesHelper { // must remove as its a valid option and we could configure it it.remove(); rc = true; - } else if (failOnNotSet) { + } else if (failIfNotSet) { throw new IllegalArgumentException("Cannot configure option [" + name + "] with value [" + stringValue + "] as the bean class [" + ObjectHelper.classCanonicalName(target) + "] has no suitable setter method, or not possible to lookup a bean with the id [" + stringValue + "] in Spring Boot registry");
