checkstyle WhiteAround

WhiteAroundCheck script
This commit is contained in:
Gary Russell
2016-04-05 13:29:21 -04:00
parent 842aded9a4
commit 05cc7be644
508 changed files with 2027 additions and 1916 deletions

View File

@@ -104,7 +104,7 @@ public class OperationInvokingMessageHandlerTests {
handler.handleMessage(message);
}
@Test(expected=MessagingException.class)
@Test(expected = MessagingException.class)
public void invocationWithMapPayloadNotEnoughParameters() throws Exception {
QueueChannel outputChannel = new QueueChannel();
OperationInvokingMessageHandler handler = new OperationInvokingMessageHandler();
@@ -164,7 +164,7 @@ public class OperationInvokingMessageHandlerTests {
}
@Override
public void y(String s){}
public void y(String s) { }
}
}

View File

@@ -103,7 +103,7 @@ public class CustomObjectNameTests {
assertTrue(AopUtils.isJdkDynamicProxy(this.customHandler));
}
@IntegrationManagedResource(objectName="${customChannelName}", description="custom channel")
@IntegrationManagedResource(objectName = "${customChannelName}", description = "custom channel")
public static class ChannelWithCustomObjectName extends AbstractMessageChannel {
@Override
@@ -113,9 +113,9 @@ public class CustomObjectNameTests {
}
@IntegrationManagedResource(objectName="${customHandlerName}", description="custom handler",
currencyTimeLimit=1000, log=true, logFile="foo", persistLocation="bar", persistName="baz", persistPeriod=10,
persistPolicy="Never")
@IntegrationManagedResource(objectName = "${customHandlerName}", description = "custom handler",
currencyTimeLimit = 1000, log = true, logFile = "foo", persistLocation = "bar", persistName = "baz", persistPeriod = 10,
persistPolicy = "Never")
@Transactional
public static class HandlerWithCustomObjectName extends AbstractMessageHandler {

View File

@@ -75,7 +75,7 @@ public class MBeanRegistrationTests {
public void testServiceActivatorMBeanHasTrackableComponent() throws Exception {
System.err.println(server.queryNames(new ObjectName("test.MBeanRegistration:*"), null));
Set<ObjectName> names = server.queryNames(new ObjectName("test.MBeanRegistration:type=ServiceActivatingHandler,name=service,*"), null);
Map<String,MBeanOperationInfo> infos = new HashMap<String, MBeanOperationInfo>();
Map<String, MBeanOperationInfo> infos = new HashMap<String, MBeanOperationInfo>();
for (MBeanOperationInfo info : server.getMBeanInfo(names.iterator().next()).getOperations()) {
infos.put(info.getName(), info);
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2015 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -148,7 +148,7 @@ public class NotificationPublishingChannelAdapterParserTests {
for (ObjectInstance mbean : mbeans) {
if (mbean.toString().contains("MessageHistoryConfigurer")) {
ObjectName objectName = mbean.getObjectName();
try{
try {
server.setAttribute(objectName, new Attribute("ComponentNamePatternsString", "foo, bar"));
fail("Exception expected");
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2015 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -121,7 +121,7 @@ public class OperationInvokingChannelAdapterParserTests {
}
}
private Message<?> createMessage(String payload){
private Message<?> createMessage(String payload) {
return MessageBuilder.withPayload(payload)
.setHeader(JmxHeaders.OBJECT_NAME, "org.springframework.integration.jmx.config:type=TestBean,name=foo")
.setHeader(JmxHeaders.OPERATION_NAME, "blah").build();

View File

@@ -32,13 +32,13 @@ import org.springframework.util.Assert;
*
*/
@ManagedResource
public class SimpleDynamicRouter{
public class SimpleDynamicRouter {
private final Map<String, String> channelMappings = new HashMap<String, String>();
/**
*
* @param channelMappings
*/
public SimpleDynamicRouter(Map<String, String> channelMappings){
public SimpleDynamicRouter(Map<String, String> channelMappings) {
Assert.notEmpty(channelMappings, "you must provide at least one channel mappings");
for (String key : channelMappings.keySet()) {
this.channelMappings.put(key, channelMappings.get(key));
@@ -50,27 +50,27 @@ public class SimpleDynamicRouter{
* @param channelName
*/
@ManagedOperation
public void addChannelMapping(String key, String channelName){
public void addChannelMapping(String key, String channelName) {
this.channelMappings.put(key, channelName);
}
/**
*
* @param key
*/
public void removeChannelMapping(String key){
public void removeChannelMapping(String key) {
this.channelMappings.remove(key);
}
/**
*
*/
public Map<String, String> getChannelMappings(){
public Map<String, String> getChannelMappings() {
return channelMappings;
}
/**
*
* @param key
*/
public String route(Object key){
public String route(Object key) {
String className = key.getClass().getName();
return this.channelMappings.get(className);
}

View File

@@ -42,17 +42,17 @@ public class ChainWithMessageProducingHandlersTests {
private ApplicationContext applicationContext;
@Test
public void testSuccessfulApplicationContext(){
public void testSuccessfulApplicationContext() {
// this is all we need to do. Until INT-1431 was solved initialization of this AC would fail.
assertNotNull(applicationContext);
}
public static class SampleProducer{
public String echo(String value){
public static class SampleProducer {
public String echo(String value) {
return value;
}
}
public static class SampleService{
public void echo(String value){}
public static class SampleService {
public void echo(String value) { }
}
}

View File

@@ -127,7 +127,7 @@ public class HandlerMonitoringIntegrationTests {
public static class HandlerInterceptor {
@Before("execution(* *..*Tests*(String)) && args(input)")
public void around(String input) {
logger.debug("Handling: "+input);
logger.debug("Handling: " + input);
}
}

View File

@@ -64,7 +64,7 @@ public class MBeanExporterIntegrationTests {
@After
public void close() {
if (context!=null) {
if (context != null) {
context.close();
}
}
@@ -378,7 +378,7 @@ public class MBeanExporterIntegrationTests {
public String execute() throws Exception {
Thread.sleep(10L); // make the duration non-zero
counter++;
return "count="+counter;
return "count=" + counter;
}
@Override

View File

@@ -90,7 +90,7 @@ public class MessageSourceMonitoringIntegrationTests {
public String execute() throws Exception {
Thread.sleep(10L); // make the duration non-zero
counter++;
return "count="+counter;
return "count=" + counter;
}
public int getCounter() {