You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by gz...@apache.org on 2019/04/08 06:53:42 UTC
[camel] 02/04: [Minor] Use Java-style array declaration
This is an automated email from the ASF dual-hosted git repository.
gzurowski pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 42aef3687676425ca3d0914c5f3363a4a5536e6e
Author: Gregor Zurowski <gr...@zurowski.org>
AuthorDate: Mon Apr 8 08:36:40 2019 +0200
[Minor] Use Java-style array declaration
---
.../src/main/java/org/apache/camel/impl/AbstractCamelContext.java | 2 +-
.../src/main/java/org/apache/camel/reifier/ToDynamicReifier.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/core/camel-core/src/main/java/org/apache/camel/impl/AbstractCamelContext.java b/core/camel-core/src/main/java/org/apache/camel/impl/AbstractCamelContext.java
index 8cc4210..2ea5ab7 100644
--- a/core/camel-core/src/main/java/org/apache/camel/impl/AbstractCamelContext.java
+++ b/core/camel-core/src/main/java/org/apache/camel/impl/AbstractCamelContext.java
@@ -711,7 +711,7 @@ public abstract class AbstractCamelContext extends ServiceSupport implements Mod
if (answer == null) {
try {
// Use the URI prefix to find the component.
- String splitURI[] = StringHelper.splitOnCharacter(uri, ":", 2);
+ String[] splitURI = StringHelper.splitOnCharacter(uri, ":", 2);
if (splitURI[1] != null) {
scheme = splitURI[0];
log.trace("Endpoint uri: {} is from component with name: {}", uri, scheme);
diff --git a/core/camel-core/src/main/java/org/apache/camel/reifier/ToDynamicReifier.java b/core/camel-core/src/main/java/org/apache/camel/reifier/ToDynamicReifier.java
index fa67c0b..0b1d264 100644
--- a/core/camel-core/src/main/java/org/apache/camel/reifier/ToDynamicReifier.java
+++ b/core/camel-core/src/main/java/org/apache/camel/reifier/ToDynamicReifier.java
@@ -112,7 +112,7 @@ class ToDynamicReifier<T extends ToDynamicDefinition> extends ProcessorReifier<T
// there is a plus sign so we need to split in a safe manner
List<Pair<Integer>> rawPairs = URISupport.scanRaw(s);
StringBuilder sb = new StringBuilder();
- char chars[] = s.toCharArray();
+ char[] chars = s.toCharArray();
for (int i = 0; i < chars.length; i++) {
char ch = chars[i];
if (ch != '+' || URISupport.isRaw(i, rawPairs)) {