Added JavaDoc for @Router and @Splitter (INT-273).
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2007 the original author or authors.
|
||||
* Copyright 2002-2008 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.
|
||||
@@ -25,8 +25,23 @@ import java.lang.annotation.Target;
|
||||
|
||||
/**
|
||||
* Indicates that a method is capable of resolving to a channel or channel name
|
||||
* based on a message, message payload, message attribute, or message property.
|
||||
*
|
||||
* based on a message, message header(s), or both.
|
||||
* <p>
|
||||
* A method annotated with @Router may accept a parameter of type
|
||||
* {@link org.springframework.integration.message.Message} or of the expected
|
||||
* Message payload's type. Any type conversion supported by
|
||||
* {@link org.springframework.beans.SimpleTypeConverter} will be applied to
|
||||
* the Message payload if necessary. Header values can also be passed as
|
||||
* Message parameters by using the
|
||||
* {@link org.springframework.integration.handler.annotation.Header @Header}
|
||||
* parameter annotation.
|
||||
* <p>
|
||||
* Return values from the annotated method may be either a Collection or Array
|
||||
* whose elements are either
|
||||
* {@link org.springframework.integration.channel.MessageChannel channels} or
|
||||
* Strings. In the latter case, the endpoint hosting this router will attempt
|
||||
* to resolve each channel name with the Channel Registry.
|
||||
*
|
||||
* @author Mark Fisher
|
||||
*/
|
||||
@Target(ElementType.METHOD)
|
||||
|
||||
@@ -25,6 +25,19 @@ import java.lang.annotation.Target;
|
||||
/**
|
||||
* Indicates that a method is capable of splitting a single message or message
|
||||
* payload to produce multiple messages or payloads.
|
||||
* <p>
|
||||
* A method annotated with @Splitter may accept a parameter of type
|
||||
* {@link org.springframework.integration.message.Message} or of the expected
|
||||
* Message payload's type. Any type conversion supported by
|
||||
* {@link org.springframework.beans.SimpleTypeConverter} will be applied to
|
||||
* the Message payload if necessary. Header values can also be passed as
|
||||
* Message parameters by using the
|
||||
* {@link org.springframework.integration.handler.annotation.Header @Header}
|
||||
* parameter annotation.
|
||||
* <p>
|
||||
* Return values from the annotated method may be either a Collection or Array
|
||||
* with elements of any type. If the type is not a Message, each will be used
|
||||
* as the payload for creating a new Message.
|
||||
*
|
||||
* @author Mark Fisher
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user