Refactored MethodInvokingSource to the "message" package and MethodInvokingTarget to the "handler" package. The "adapter" package has been removed (INT-215).
This commit is contained in:
@@ -34,8 +34,6 @@ import org.springframework.beans.factory.config.BeanPostProcessor;
|
||||
import org.springframework.core.OrderComparator;
|
||||
import org.springframework.core.annotation.AnnotationUtils;
|
||||
import org.springframework.integration.ConfigurationException;
|
||||
import org.springframework.integration.adapter.MethodInvokingSource;
|
||||
import org.springframework.integration.adapter.MethodInvokingTarget;
|
||||
import org.springframework.integration.annotation.Aggregator;
|
||||
import org.springframework.integration.annotation.CompletionStrategy;
|
||||
import org.springframework.integration.annotation.Concurrency;
|
||||
@@ -54,8 +52,10 @@ import org.springframework.integration.endpoint.PollingSourceEndpoint;
|
||||
import org.springframework.integration.handler.AbstractMessageHandlerAdapter;
|
||||
import org.springframework.integration.handler.MessageHandler;
|
||||
import org.springframework.integration.handler.MessageHandlerChain;
|
||||
import org.springframework.integration.handler.MethodInvokingTarget;
|
||||
import org.springframework.integration.handler.config.DefaultMessageHandlerCreator;
|
||||
import org.springframework.integration.handler.config.MessageHandlerCreator;
|
||||
import org.springframework.integration.message.MethodInvokingSource;
|
||||
import org.springframework.integration.router.AggregatingMessageHandler;
|
||||
import org.springframework.integration.router.CompletionStrategyAdapter;
|
||||
import org.springframework.integration.router.config.AggregatorMessageHandlerCreator;
|
||||
|
||||
@@ -21,8 +21,8 @@ import org.w3c.dom.Element;
|
||||
import org.springframework.beans.factory.support.BeanDefinitionBuilder;
|
||||
import org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser;
|
||||
import org.springframework.integration.ConfigurationException;
|
||||
import org.springframework.integration.adapter.MethodInvokingSource;
|
||||
import org.springframework.integration.adapter.MethodInvokingTarget;
|
||||
import org.springframework.integration.handler.MethodInvokingTarget;
|
||||
import org.springframework.integration.message.MethodInvokingSource;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
/**
|
||||
|
||||
@@ -18,8 +18,8 @@ package org.springframework.integration.config;
|
||||
|
||||
import org.w3c.dom.Element;
|
||||
|
||||
import org.springframework.integration.adapter.MethodInvokingTarget;
|
||||
import org.springframework.integration.endpoint.TargetEndpoint;
|
||||
import org.springframework.integration.handler.MethodInvokingTarget;
|
||||
|
||||
/**
|
||||
* Parser for the <target-endpoint> element.
|
||||
|
||||
@@ -14,9 +14,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.handler;
|
||||
|
||||
import org.springframework.integration.handler.AbstractMessageHandlerAdapter;
|
||||
import org.springframework.integration.message.Message;
|
||||
import org.springframework.integration.message.MessagingException;
|
||||
import org.springframework.integration.message.Target;
|
||||
@@ -14,17 +14,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.message;
|
||||
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
import org.springframework.beans.factory.InitializingBean;
|
||||
import org.springframework.integration.ConfigurationException;
|
||||
import org.springframework.integration.message.GenericMessage;
|
||||
import org.springframework.integration.message.Message;
|
||||
import org.springframework.integration.message.MessagingException;
|
||||
import org.springframework.integration.message.Source;
|
||||
import org.springframework.integration.util.MethodValidator;
|
||||
import org.springframework.integration.util.NameResolvingMethodInvoker;
|
||||
import org.springframework.util.Assert;
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.handler;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertNotNull;
|
||||
@@ -32,7 +32,7 @@ import org.springframework.context.support.ClassPathXmlApplicationContext;
|
||||
/**
|
||||
* @author Mark Fisher
|
||||
*/
|
||||
public class AdapterTests {
|
||||
public class MethodInvokingAdapterTests {
|
||||
|
||||
@Test
|
||||
public void testAdaptersWithBeanDefinitions() throws IOException, InterruptedException {
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.handler;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertNotNull;
|
||||
@@ -29,6 +29,7 @@ import org.junit.Test;
|
||||
|
||||
import org.springframework.integration.bus.MessageBus;
|
||||
import org.springframework.integration.channel.QueueChannel;
|
||||
import org.springframework.integration.handler.MethodInvokingTarget;
|
||||
import org.springframework.integration.message.GenericMessage;
|
||||
import org.springframework.integration.message.Message;
|
||||
import org.springframework.integration.message.MessagingException;
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.handler;
|
||||
|
||||
import java.util.concurrent.CountDownLatch;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.handler;
|
||||
|
||||
/**
|
||||
* @author Mark Fisher
|
||||
@@ -12,9 +12,9 @@
|
||||
|
||||
<bean id="sourceEndpoint" class="org.springframework.integration.endpoint.PollingSourceEndpoint">
|
||||
<constructor-arg>
|
||||
<bean class="org.springframework.integration.adapter.MethodInvokingSource">
|
||||
<bean class="org.springframework.integration.message.MethodInvokingSource">
|
||||
<property name="object">
|
||||
<bean class="org.springframework.integration.adapter.TestSource"/>
|
||||
<bean class="org.springframework.integration.handler.TestSource"/>
|
||||
</property>
|
||||
<property name="method" value="foo"/>
|
||||
</bean>
|
||||
@@ -27,7 +27,7 @@
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
|
||||
<bean id="target" class="org.springframework.integration.adapter.MethodInvokingTarget">
|
||||
<bean id="target" class="org.springframework.integration.handler.MethodInvokingTarget">
|
||||
<property name="object" ref="sink"/>
|
||||
<property name="methodName" value="store"/>
|
||||
</bean>
|
||||
@@ -41,6 +41,6 @@
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="sink" class="org.springframework.integration.adapter.TestSink"/>
|
||||
<bean id="sink" class="org.springframework.integration.handler.TestSink"/>
|
||||
|
||||
</beans>
|
||||
@@ -19,8 +19,8 @@
|
||||
|
||||
<si:source-adapter id="sourceAdapter" ref="source" method="foo"/>
|
||||
|
||||
<bean id="source" class="org.springframework.integration.adapter.TestSource"/>
|
||||
<bean id="source" class="org.springframework.integration.handler.TestSource"/>
|
||||
|
||||
<bean id="sink" class="org.springframework.integration.adapter.TestSink"/>
|
||||
<bean id="sink" class="org.springframework.integration.handler.TestSink"/>
|
||||
|
||||
</beans>
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.integration.adapter;
|
||||
package org.springframework.integration.message;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertNotNull;
|
||||
@@ -23,6 +23,7 @@ import org.junit.Test;
|
||||
|
||||
import org.springframework.integration.message.Message;
|
||||
import org.springframework.integration.message.MessagingException;
|
||||
import org.springframework.integration.message.MethodInvokingSource;
|
||||
|
||||
/**
|
||||
* @author Mark Fisher
|
||||
Reference in New Issue
Block a user