クラス IntegrationFlowAdapter
java.lang.ObjectSE
org.springframework.integration.dsl.IntegrationFlowAdapter
- 実装されたすべてのインターフェース:
Aware
、BeanNameAware
、Lifecycle
、Phased
、SmartLifecycle
、ComponentSourceAware
、IntegrationFlow
、ManageableLifecycle
、ManageableSmartLifecycle
public abstract class IntegrationFlowAdapter
extends ObjectSE
implements IntegrationFlow, ManageableSmartLifecycle, ComponentSourceAware
IntegrationFlow
抽象化の基本 Adapter
クラス。from(java.lang.String)
サポートメソッドの 1 つを使用して IntegrationFlowDefinition
を生成するには、buildFlow()
メソッドの実装が必要です。通常、ターゲットサービスの実装に使用されます。
@Component public class MyFlowAdapter extends IntegrationFlowAdapter { @Autowired private ConnectionFactory rabbitConnectionFactory; @Override protected IntegrationFlowDefinition<?> buildFlow() { return from(Amqp.inboundAdapter(this.rabbitConnectionFactory, "myQueue")) .<String, String>transform(String::toLowerCase) .channel(c -> c.queue("myFlowAdapterOutput")); } }
- 導入:
- 5.0
- 作成者:
- Artem Bilan
フィールドのサマリー
インターフェース org.springframework.context.SmartLifecycle から継承されたフィールド
DEFAULT_PHASE
コンストラクターの概要
コンストラクターメソッドのサマリー
修飾子と型メソッド説明protected abstract IntegrationFlowDefinition
<?> final void
configure
(IntegrationFlowDefinition<?> flow) EIP メソッドのチェーンを宣言して、提供されたIntegrationFlowDefinition
との統合フローを構成するためのコールバックベースの関数。protected IntegrationFlowBuilder
protected IntegrationFlowBuilder
from
(ClassSE<?> serviceInterface, ConsumerSE<GatewayProxySpec> endpointConfigurer) サービスインターフェースのプロキシからフローを開始します。protected IntegrationFlowDefinition
<?> protected IntegrationFlowDefinition
<?> protected IntegrationFlowBuilder
protected IntegrationFlowDefinition
<?> from
(MessageSource<?> messageSource) protected IntegrationFlowDefinition
<?> from
(MessageSource<?> messageSource, ConsumerSE<SourcePollingChannelAdapterSpec> endpointConfigurer) protected IntegrationFlowDefinition
<?> from
(MessageChannelSpec<?, ?> messageChannelSpec) protected IntegrationFlowDefinition
<?> from
(MessageProducerSpec<?, ?> messageProducerSpec) protected IntegrationFlowDefinition
<?> from
(MessageSourceSpec<?, ? extends MessageSource<?>> messageSourceSpec) protected IntegrationFlowDefinition
<?> from
(MessageSourceSpec<?, ? extends MessageSource<?>> messageSourceSpec, ConsumerSE<SourcePollingChannelAdapterSpec> endpointConfigurer) protected IntegrationFlowDefinition
<?> from
(MessagingGatewaySpec<?, ?> inboundGatewaySpec) protected IntegrationFlowDefinition
<?> from
(MessageProducerSupport messageProducer) protected IntegrationFlowDefinition
<?> from
(MessagingGatewaySupport inboundGateway) protected IntegrationFlowDefinition
<?> from
(MessageChannel messageChannel) protected <T> IntegrationFlowBuilder
fromSupplier
(SupplierSE<T> messageSource) protected <T> IntegrationFlowBuilder
fromSupplier
(SupplierSE<T> messageSource, ConsumerSE<SourcePollingChannelAdapterSpec> endpointConfigurer) BeanNameAware.setBeanName(String)
によって設定された Bean 名を返します。この Bean の人間が読める形式の説明を返します。この Bean の構成ソースObject
(おそらくnull
) を返します。基本的にフロー入力チャネルである最初のMessageChannel
コンポーネントを返します。このフローによって管理される統合コンポーネントのマップを返します(存在する場合)。int
getPhase()
boolean
boolean
void
setBeanName
(StringSE name) void
setComponentDescription
(StringSE description) この Bean の人間が読める説明を設定します。void
setComponentSource
(ObjectSE source) この Bean 定義の構成ソースObject
を設定します。void
start()
void
stop()
void
stop
(RunnableSE callback)
コンストラクターの詳細
IntegrationFlowAdapter
public IntegrationFlowAdapter()
メソッドの詳細
setBeanName
- 次で指定:
- インターフェース
BeanNameAware
のsetBeanName
getBeanName
インターフェースからコピーされた説明:ComponentSourceAware
BeanNameAware.setBeanName(String)
によって設定された Bean 名を返します。- 次で指定:
- インターフェース
ComponentSourceAware
のgetBeanName
- 戻り値:
- Bean 名。
setComponentSource
インターフェースからコピーされた説明:ComponentSourceAware
この Bean 定義の構成ソースObject
を設定します。通常のBeanDefinition
の場合、これはアプリケーションコンテキストによって自動的に提供されます。Bean が実行時にSingletonBeanRegistry.registerSingleton(String, Object)
経由で登録される場合に役立ちます。- 次で指定:
- インターフェース
ComponentSourceAware
のsetComponentSource
- パラメーター:
source
- 構成ソース
getComponentSource
インターフェースからコピーされた説明:ComponentSourceAware
この Bean の構成ソースObject
を返します (null
の場合もあります)。通常は (明示的に設定されていない場合は)BeanMetadataElement.getSource()
です。- 次で指定:
- インターフェース
ComponentSourceAware
のgetComponentSource
- 戻り値:
- Bean の構成ソース (存在する場合)。
setComponentDescription
インターフェースからコピーされた説明:ComponentSourceAware
この Bean の人間が読める説明を設定します。通常の Bean 定義ではBeanDefinition.getDescription()
が使用されます。- 次で指定:
- インターフェース
ComponentSourceAware
のsetComponentDescription
- パラメーター:
description
- Bean の説明
getComponentDescription
インターフェースからコピーされた説明:ComponentSourceAware
この Bean の人間が読める形式の説明を返します。通常は (明示的に設定されていない場合は)BeanDefinition.getDescription()
です。- 次で指定:
- インターフェース
ComponentSourceAware
のgetComponentDescription
- 戻り値:
- Bean の説明 (ある場合)。
configure
インターフェースからコピーされた説明:IntegrationFlow
EIP メソッドのチェーンを宣言して、提供されたIntegrationFlowDefinition
との統合フローを構成するためのコールバックベースの関数。- 次で指定:
- インターフェース
IntegrationFlow
のconfigure
- パラメーター:
flow
- 構成するIntegrationFlowDefinition
getInputChannel
インターフェースからコピーされた説明:IntegrationFlow
基本的にフロー入力チャネルである最初のMessageChannel
コンポーネントを返します。- 次で指定:
- インターフェース
IntegrationFlow
のgetInputChannel
- 戻り値:
- チャンネル。
getIntegrationComponents
インターフェースからコピーされた説明:IntegrationFlow
このフローによって管理される統合コンポーネントのマップを返します(存在する場合)。- 次で指定:
- インターフェース
IntegrationFlow
のgetIntegrationComponents
- 戻り値:
- このフローによって管理される統合コンポーネントのマップ。
start
public void start()- 次で指定:
- インターフェース
Lifecycle
のstart
- 次で指定:
- インターフェース
ManageableLifecycle
のstart
stop
- 次で指定:
- インターフェース
SmartLifecycle
のstop
stop
public void stop()- 次で指定:
- インターフェース
Lifecycle
のstop
- 次で指定:
- インターフェース
ManageableLifecycle
のstop
isRunning
public boolean isRunning()- 次で指定:
- インターフェース
Lifecycle
のisRunning
- 次で指定:
- インターフェース
ManageableLifecycle
のisRunning
isAutoStartup
public boolean isAutoStartup()- 次で指定:
- インターフェース
SmartLifecycle
のisAutoStartup
getPhase
public int getPhase()- 次で指定:
- インターフェース
Phased
のgetPhase
- 次で指定:
- インターフェース
SmartLifecycle
のgetPhase
from
from
from
from
protected IntegrationFlowDefinition<?> from(MessageSourceSpec<?, ? extends MessageSource<?>> messageSourceSpec, ConsumerSE<SourcePollingChannelAdapterSpec> endpointConfigurer) from
protected IntegrationFlowDefinition<?> from(MessageSource<?> messageSource, ConsumerSE<SourcePollingChannelAdapterSpec> endpointConfigurer) from
from
from
from
from
from
protected IntegrationFlowDefinition<?> from(MessageSourceSpec<?, ? extends MessageSource<?>> messageSourceSpec) from
fromSupplier
fromSupplier
protected <T> IntegrationFlowBuilder fromSupplier(SupplierSE<T> messageSource, ConsumerSE<SourcePollingChannelAdapterSpec> endpointConfigurer) from
from
protected IntegrationFlowBuilder from(ClassSE<?> serviceInterface, @Nullable ConsumerSE<GatewayProxySpec> endpointConfigurer) サービスインターフェースのプロキシからフローを開始します。- パラメーター:
serviceInterface
- サービスインターフェースクラス。endpointConfigurer
- ゲートウェイのプロキシ Bean を構成するためのConsumer
SE。- 戻り値:
- 新しい
IntegrationFlowBuilder
。 - 導入:
- 5.2
from
protected IntegrationFlowBuilder from(org.reactivestreams.Publisher<? extends Message<?>> publisher) buildFlow