Some documentations clean up

This commit is contained in:
Artem Bilan
2022-07-05 16:12:16 -04:00
parent 53dd050c5b
commit bb91fd3cb3
3 changed files with 12 additions and 6 deletions

View File

@@ -156,7 +156,7 @@ public interface IntegrationFlow {
/**
* Populate the {@link MessageChannel} name to the new {@link IntegrationFlowBuilder} chain.
* Typically for the {@link org.springframework.integration.channel.FixedSubscriberChannel} together
* Typically, for the {@link org.springframework.integration.channel.FixedSubscriberChannel} together
* with {@code fixedSubscriber = true}.
* The {@link IntegrationFlow} {@code inputChannel}.
* @param messageChannelName the name for {@link DirectChannel} or
@@ -215,6 +215,7 @@ public interface IntegrationFlow {
*/
static IntegrationFlowBuilder from(MessageSourceSpec<?, ? extends MessageSource<?>> messageSourceSpec,
Consumer<SourcePollingChannelAdapterSpec> endpointConfigurer) {
Assert.notNull(messageSourceSpec, "'messageSourceSpec' must not be null");
return from(messageSourceSpec.get(), endpointConfigurer, registerComponents(messageSourceSpec));
}
@@ -248,7 +249,7 @@ public interface IntegrationFlow {
Consumer<SourcePollingChannelAdapterSpec> endpointConfigurer) {
Assert.notNull(messageSource, "'messageSource' must not be null");
return from(new AbstractMessageSource<Object>() {
return from(new AbstractMessageSource<>() {
@Override
protected Object doReceive() {
@@ -497,10 +498,9 @@ public interface IntegrationFlow {
@SuppressWarnings("unchecked")
private static <T> T extractProxyTarget(T target) {
if (!(target instanceof Advised)) {
if (!(target instanceof Advised advised)) {
return target;
}
Advised advised = (Advised) target;
try {
return (T) extractProxyTarget(advised.getTargetSource().getTarget());
}

View File

@@ -41,7 +41,7 @@ import org.springframework.messaging.MessageChannel;
*
* @see org.springframework.integration.dsl.context.IntegrationFlowBeanPostProcessor
*
* @deprecated Since version 6.0, this factory is not recommended to use as it shall be removed in the following versions. Use fluent API methods straight from {@link IntegrationFlow} interface.
* @deprecated since version 6.0 in favor of fluent API methods straight from {@link IntegrationFlow} interface.
*/
@Deprecated(since = "6.0", forRemoval = true)
public final class IntegrationFlows {