From 3ea4a2c9d9cd7278f219016d5ea01506719d035f Mon Sep 17 00:00:00 2001 From: Mark Fisher Date: Tue, 30 Jun 2009 22:25:40 +0000 Subject: [PATCH] INT-606 Added support for the 'delete-source-files' attribute on the 'outbound-channel-adapter' in the file namespace. --- .../file/config/FileOutboundChannelAdapterParser.java | 2 ++ .../file/config/spring-integration-file-1.0.xsd | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/org.springframework.integration.file/src/main/java/org/springframework/integration/file/config/FileOutboundChannelAdapterParser.java b/org.springframework.integration.file/src/main/java/org/springframework/integration/file/config/FileOutboundChannelAdapterParser.java index da9799b95c..831da29d37 100644 --- a/org.springframework.integration.file/src/main/java/org/springframework/integration/file/config/FileOutboundChannelAdapterParser.java +++ b/org.springframework.integration.file/src/main/java/org/springframework/integration/file/config/FileOutboundChannelAdapterParser.java @@ -22,6 +22,7 @@ import org.springframework.beans.factory.support.AbstractBeanDefinition; import org.springframework.beans.factory.support.BeanDefinitionBuilder; import org.springframework.beans.factory.xml.ParserContext; import org.springframework.integration.config.xml.AbstractOutboundChannelAdapterParser; +import org.springframework.integration.config.xml.IntegrationNamespaceUtils; import org.springframework.integration.context.IntegrationContextUtils; import org.springframework.util.StringUtils; @@ -47,6 +48,7 @@ public class FileOutboundChannelAdapterParser extends AbstractOutboundChannelAda .genericBeanDefinition("org.springframework.integration.file.FileWritingMessageHandler"); builder.addConstructorArgValue(directory); builder.addPropertyReference("outputChannel", IntegrationContextUtils.NULL_CHANNEL_BEAN_NAME); + IntegrationNamespaceUtils.setValueIfAttributeDefined(builder, element, "delete-source-files"); String fileNameGenerator = element.getAttribute("filename-generator"); if (StringUtils.hasText(fileNameGenerator)) { builder.addPropertyReference("fileNameGenerator", fileNameGenerator); diff --git a/org.springframework.integration.file/src/main/resources/org/springframework/integration/file/config/spring-integration-file-1.0.xsd b/org.springframework.integration.file/src/main/resources/org/springframework/integration/file/config/spring-integration-file-1.0.xsd index dfd58f548a..f887d184fb 100644 --- a/org.springframework.integration.file/src/main/resources/org/springframework/integration/file/config/spring-integration-file-1.0.xsd +++ b/org.springframework.integration.file/src/main/resources/org/springframework/integration/file/config/spring-integration-file-1.0.xsd @@ -105,6 +105,16 @@ + + + + +