Formatting.

This commit is contained in:
Mark Fisher
2008-10-13 14:00:27 +00:00
parent f99911cf89
commit 6b6db1b59a
2 changed files with 15 additions and 15 deletions

View File

@@ -131,19 +131,6 @@ public class DefaultMessageBus implements MessageBus, ApplicationContextAware, A
return null;
}
public void registerEndpoint(MessageEndpoint endpoint) {
Assert.notNull(endpoint, "'endpoint' must not be null");
if (!this.endpoints.contains(endpoint)) {
this.endpoints.add(endpoint);
}
if (this.isRunning()) {
this.activateEndpoint(endpoint);
}
if (logger.isInfoEnabled()) {
logger.info("registered endpoint '" + endpoint + "'");
}
}
public MessageEndpoint lookupEndpoint(String endpointName) {
if (this.applicationContext.containsBean(endpointName)) {
Object bean = this.applicationContext.getBean(endpointName);
@@ -160,6 +147,19 @@ public class DefaultMessageBus implements MessageBus, ApplicationContextAware, A
return this.endpoints;
}
public void registerEndpoint(MessageEndpoint endpoint) {
Assert.notNull(endpoint, "'endpoint' must not be null");
if (!this.endpoints.contains(endpoint)) {
this.endpoints.add(endpoint);
}
if (this.isRunning()) {
this.activateEndpoint(endpoint);
}
if (logger.isInfoEnabled()) {
logger.info("registered endpoint '" + endpoint + "'");
}
}
private void activateEndpoints() {
for (MessageEndpoint endpoint : this.getEndpoints()) {
if (endpoint != null) {

View File

@@ -18,11 +18,11 @@ package org.springframework.integration.bus;
/**
* Interface to be implemented by classes which need access to the {@link MessageBus}.
*
* @author Marius Bogoevici
*
*/
public interface MessageBusAware {
public void setMessageBus(MessageBus messageBus);
}