From 76a20e57d015a7d08a94beea6070813870cd0338 Mon Sep 17 00:00:00 2001 From: Mark Fisher Date: Fri, 7 Nov 2008 16:54:29 +0000 Subject: [PATCH] SourcePollingChannelAdapter no longer implements BeanNameAware since it inherits that implementation from AbstractEndpoint already. --- .../endpoint/SourcePollingChannelAdapter.java | 26 +++++++++---------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/org.springframework.integration/src/main/java/org/springframework/integration/endpoint/SourcePollingChannelAdapter.java b/org.springframework.integration/src/main/java/org/springframework/integration/endpoint/SourcePollingChannelAdapter.java index 0782b4ba65..ae6c8adb21 100644 --- a/org.springframework.integration/src/main/java/org/springframework/integration/endpoint/SourcePollingChannelAdapter.java +++ b/org.springframework.integration/src/main/java/org/springframework/integration/endpoint/SourcePollingChannelAdapter.java @@ -16,7 +16,6 @@ package org.springframework.integration.endpoint; -import org.springframework.beans.factory.BeanNameAware; import org.springframework.integration.channel.MessageChannelTemplate; import org.springframework.integration.core.Message; import org.springframework.integration.core.MessageChannel; @@ -25,14 +24,11 @@ import org.springframework.util.Assert; /** * A Channel Adapter implementation for connecting a - * {@link org.springframework.integration.message.MessageSource} - * to a {@link MessageChannel}. + * {@link MessageSource} to a {@link MessageChannel}. * * @author Mark Fisher */ -public class SourcePollingChannelAdapter extends AbstractPollingEndpoint implements BeanNameAware { - - private volatile String name; +public class SourcePollingChannelAdapter extends AbstractPollingEndpoint { private volatile MessageSource source; @@ -41,18 +37,24 @@ public class SourcePollingChannelAdapter extends AbstractPollingEndpoint impleme private final MessageChannelTemplate channelTemplate = new MessageChannelTemplate(); - public void setBeanName(String beanName) { - this.name = beanName; - } - + /** + * Specify the source to be polled for Messages. + */ public void setSource(MessageSource source) { this.source = source; } + /** + * Specify the {@link MessageChannel} where Messages should be sent. + */ public void setOutputChannel(MessageChannel outputChannel) { this.outputChannel = outputChannel; } + /** + * Specify the maximum time to wait for a Message to be sent to the + * output channel. + */ public void setSendTimeout(long sendTimeout) { this.channelTemplate.setSendTimeout(sendTimeout); } @@ -77,8 +79,4 @@ public class SourcePollingChannelAdapter extends AbstractPollingEndpoint impleme return false; } - public String toString() { - return this.name; - } - }