Fix some other CS errors
Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/eba07da4 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/eba07da4 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/eba07da4 Branch: refs/heads/master Commit: eba07da4ec1a464479eca03a19c491044931718d Parents: 23da7dd Author: Willem Jiang <ningji...@apache.org> Authored: Tue May 7 14:38:44 2013 +0800 Committer: Willem Jiang <ningji...@apache.org> Committed: Tue May 7 14:38:44 2013 +0800 ---------------------------------------------------------------------- .../link/BindySimpleFixedLengthWithLinkTest.java | 2 +- .../apache/camel/component/ical/ICalConverter.java | 7 ++++- .../camel/component/ical/ICalDataFormat.java | 2 +- .../camel/component/ical/ICalDataFormatTest.java | 2 +- .../jms/JmsComponentConfigurationTest.java | 19 ++++++++------- .../component/netty/http/NettyHttpProducer.java | 16 ++++++++++++ .../netty/handlers/ClientChannelHandler.java | 2 +- 7 files changed, 35 insertions(+), 15 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/fixed/link/BindySimpleFixedLengthWithLinkTest.java ---------------------------------------------------------------------- diff --git a/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/fixed/link/BindySimpleFixedLengthWithLinkTest.java b/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/fixed/link/BindySimpleFixedLengthWithLinkTest.java index e5d4ec2..c3dd33d 100644 --- a/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/fixed/link/BindySimpleFixedLengthWithLinkTest.java +++ b/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/fixed/link/BindySimpleFixedLengthWithLinkTest.java @@ -67,7 +67,7 @@ public class BindySimpleFixedLengthWithLinkTest extends CamelTestSupport { for (int i = 0; i < results.size(); i++) { Map<String, Object> map = results.get(i); - for ( String key : map.keySet() ) { + for (String key : map.keySet()) { if (key.equals(orderKey)) { Order order = (Order) map.get(orderKey); assertEquals("AAA", order.fieldA); http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalConverter.java ---------------------------------------------------------------------- diff --git a/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalConverter.java b/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalConverter.java index 5a3e4d9..e1ff26b 100644 --- a/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalConverter.java +++ b/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalConverter.java @@ -1,4 +1,4 @@ -/* +/** * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. @@ -31,7 +31,10 @@ import org.apache.camel.util.IOHelper; * ICal related converter. */ @Converter -public class ICalConverter { +public final class ICalConverter { + private ICalConverter() { + // Helper class + } @Converter public static Date toDate(DateProperty property) { http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalDataFormat.java ---------------------------------------------------------------------- diff --git a/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalDataFormat.java b/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalDataFormat.java index 2159b53..0448c74 100644 --- a/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalDataFormat.java +++ b/components/camel-ical/src/main/java/org/apache/camel/component/ical/ICalDataFormat.java @@ -1,4 +1,4 @@ -/* +/** * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-ical/src/test/java/org/apache/camel/component/ical/ICalDataFormatTest.java ---------------------------------------------------------------------- diff --git a/components/camel-ical/src/test/java/org/apache/camel/component/ical/ICalDataFormatTest.java b/components/camel-ical/src/test/java/org/apache/camel/component/ical/ICalDataFormatTest.java index 163a533..f588401 100644 --- a/components/camel-ical/src/test/java/org/apache/camel/component/ical/ICalDataFormatTest.java +++ b/components/camel-ical/src/test/java/org/apache/camel/component/ical/ICalDataFormatTest.java @@ -1,4 +1,4 @@ -/* +/** * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsComponentConfigurationTest.java ---------------------------------------------------------------------- diff --git a/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsComponentConfigurationTest.java b/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsComponentConfigurationTest.java index b4ca272..fef60ef 100644 --- a/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsComponentConfigurationTest.java +++ b/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsComponentConfigurationTest.java @@ -1,5 +1,4 @@ /** - * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. @@ -7,7 +6,7 @@ * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +16,12 @@ */ package org.apache.camel.component.jms; +import java.util.Map; +import java.util.Set; +import java.util.SortedMap; + +import javax.jms.ConnectionFactory; + import org.apache.camel.CamelContext; import org.apache.camel.Component; import org.apache.camel.ComponentConfiguration; @@ -27,14 +32,10 @@ import org.junit.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import javax.jms.ConnectionFactory; - -import java.util.Map; -import java.util.Set; -import java.util.SortedMap; import static org.apache.camel.component.jms.JmsComponent.jmsComponentAutoAcknowledge; + /** * Lets test the use of the ComponentConfiguration on the JMS endpoint */ @@ -43,13 +44,13 @@ public class JmsComponentConfigurationTest extends CamelTestSupport { private static final Logger LOG = LoggerFactory.getLogger(JmsComponentConfigurationTest.class); protected String componentName = "activemq456"; - protected boolean verbose = false; + protected boolean verbose; @Test public void testConfiguration() throws Exception { Component component = context().getComponent(componentName); ComponentConfiguration configuration = component.createComponentConfiguration(); - SortedMap<String,ParameterConfiguration> parameterConfigurationMap = configuration.getParameterConfigurationMap(); + SortedMap<String, ParameterConfiguration> parameterConfigurationMap = configuration.getParameterConfigurationMap(); if (verbose) { Set<Map.Entry<String, ParameterConfiguration>> entries = parameterConfigurationMap.entrySet(); for (Map.Entry<String, ParameterConfiguration> entry : entries) { http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/NettyHttpProducer.java ---------------------------------------------------------------------- diff --git a/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/NettyHttpProducer.java b/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/NettyHttpProducer.java index 7cc562b..7c52cf4 100644 --- a/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/NettyHttpProducer.java +++ b/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/NettyHttpProducer.java @@ -1,3 +1,19 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.apache.camel.component.netty.http; import org.apache.camel.Exchange; http://git-wip-us.apache.org/repos/asf/camel/blob/eba07da4/components/camel-netty/src/main/java/org/apache/camel/component/netty/handlers/ClientChannelHandler.java ---------------------------------------------------------------------- diff --git a/components/camel-netty/src/main/java/org/apache/camel/component/netty/handlers/ClientChannelHandler.java b/components/camel-netty/src/main/java/org/apache/camel/component/netty/handlers/ClientChannelHandler.java index cad92ed..d3459ba 100644 --- a/components/camel-netty/src/main/java/org/apache/camel/component/netty/handlers/ClientChannelHandler.java +++ b/components/camel-netty/src/main/java/org/apache/camel/component/netty/handlers/ClientChannelHandler.java @@ -185,7 +185,7 @@ public class ClientChannelHandler extends SimpleChannelUpstreamHandler { // if textline enabled then covert to a String which must be used for textline if (producer.getConfiguration().isTextline()) { - body = producer.getContext().getTypeConverter().mandatoryConvertTo(String.class, exchange, body); + body = producer.getContext().getTypeConverter().mandatoryConvertTo(String.class, exchange, body); } // set the result on either IN or OUT on the original exchange depending on its pattern