クラス IntegrationNamespaceUtils
java.lang.ObjectSE
org.springframework.integration.config.xml.IntegrationNamespaceUtils
統合名前空間パーサーの共有ユーティリティメソッド。
- 作成者:
- Mark Fisher, Marius Bogoevici, Alex Peters, Oleg Zhurakousky, Gary Russell, Artem Bilan, Gunnar Hillert
フィールドサマリー
フィールドコンストラクターのサマリー
コンストラクターメソッドのサマリー
修飾子と型メソッド説明static void
checkAndConfigureFixedSubscriberChannel
(ElementSE element, ParserContext parserContext, StringSE channelName, StringSE handlerBeanName) static ManagedList
configureAdviceChain
(ElementSE adviceChainElement, ElementSE txElement, boolean handleMessageAdvice, BeanDefinition parentBeanDefinition, ParserContext parserContext) static ManagedList
configureAdviceChain
(ElementSE adviceChainElement, ElementSE txElement, BeanDefinition parentBeanDefinition, ParserContext parserContext) static void
configureAndSetAdviceChainIfPresent
(ElementSE adviceChainElement, ElementSE txElement, boolean handleMessageAdvice, BeanDefinition parentBeanDefinition, ParserContext parserContext) static void
configureAndSetAdviceChainIfPresent
(ElementSE adviceChainElement, ElementSE txElement, boolean handleMessageAdvice, BeanDefinition parentBeanDefinition, ParserContext parserContext, StringSE propertyName) static void
configureAndSetAdviceChainIfPresent
(ElementSE adviceChainElement, ElementSE txElement, BeanDefinition parentBeanDefinition, ParserContext parserContext) static void
configureAndSetAdviceChainIfPresent
(ElementSE adviceChainElement, ElementSE txElement, BeanDefinition parentBeanDefinition, ParserContext parserContext, StringSE propertyName) static void
configureHeaderMapper
(ElementSE element, BeanDefinitionBuilder rootBuilder, ParserContext parserContext, ClassSE<?> headerMapperClass, StringSE replyHeaderValue) 受信および送信チャネルアダプター / ゲートウェイ用に HeaderMapper を構成するためのユーティリティメソッド。static void
configureHeaderMapper
(ElementSE element, BeanDefinitionBuilder rootBuilder, ParserContext parserContext, BeanDefinitionBuilder headerMapperBuilder, StringSE replyHeaderValueArg) 受信および送信チャネルアダプター / ゲートウェイ用に HeaderMapper を構成するためのユーティリティメソッド。static void
configurePollerMetadata
(ElementSE pollerElement, BeanDefinitionBuilder targetBuilder, ParserContext parserContext) "poller" 要素を解析して、ターゲット BeanDefinitionBuilder の参照を提供します。static BeanDefinition
configureTransactionAttributes
(ElementSE txElement) "transactional" 要素を解析し、"transactionManager" およびその他の "transactionDefinition" プロパティを使用してTransactionInterceptor
を構成します。static BeanDefinition
configureTransactionAttributes
(ElementSE txElement, boolean handleMessageAdvice) "transactional" 要素を解析し、"transactionManager" およびその他の "transactionDefinition" プロパティを使用してTransactionInterceptor
またはTransactionHandleMessageAdvice
を構成します。static BeanDefinition
configureTransactionDefinition
(ElementSE txElement) "transactional" 要素の属性を解析し、提供された "transactionDefinition" プロパティを使用してDefaultTransactionAttribute
を構成します。static StringSE
createDirectChannel
(ElementSE element, ParserContext parserContext) static StringSE
createElementDescription
(ElementSE element) ノード名に基づいた要素のわかりやすい説明と、可能な場合は "id" 属性値を提供します。static BeanDefinition
createExpressionDefIfAttributeDefined
(StringSE expressionElementName, ElementSE element) static BeanDefinition
createExpressionDefinitionFromValueOrExpression
(StringSE valueElementName, StringSE expressionElementName, ParserContext parserContext, ElementSE element, boolean oneRequired) static StringSE[]
generateAlias
(ElementSE element) static StringSE
getTextFromAttributeOrNestedElement
(ElementSE element, StringSE name, ParserContext parserContext) 名前付き属性が存在する場合はそれからテキスト値を取得します。存在しない場合は、同じ名前のネストされた要素がないかどうかを確認します。static void
injectConstructorWithAdapter
(StringSE beanRefAttribute, StringSE methodRefAttribute, StringSE expressionAttribute, StringSE adapterClass, ElementSE element, BeanDefinitionBuilder builder, BeanMetadataElement processor, ParserContext parserContext) static void
injectPropertyWithAdapter
(StringSE beanRefAttribute, StringSE methodRefAttribute, StringSE expressionAttribute, StringSE beanProperty, StringSE adapterClass, ElementSE element, BeanDefinitionBuilder builder, BeanMetadataElement processor, ParserContext parserContext) static BeanComponentDefinition
parseInnerHandlerDefinition
(ElementSE element, ParserContext parserContext) static void
setReferenceIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName) 提供されている Bean 定義ビルダーを、Bean へのプロパティ参照で構成します。static void
setReferenceIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, boolean emptyStringAllowed) static void
setReferenceIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName) 提供されている Bean 定義ビルダーを、Bean へのプロパティ参照で構成します。static void
setReferenceIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName, boolean emptyStringAllowed) static void
setValueIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。static void
setValueIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, boolean emptyStringAllowed) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。static void
setValueIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。static void
setValueIfAttributeDefined
(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName, boolean emptyStringAllowed) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。
フィールドの詳細
コンストラクターの詳細
IntegrationNamespaceUtils
public IntegrationNamespaceUtils()
メソッドの詳細
setValueIfAttributeDefined
public static void setValueIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。- パラメーター:
builder
- 構成する Bean 定義ビルダーelement
- 属性を定義する必要がある XML 要素attributeName
- プロパティの入力に使用される値を持つ属性の名前propertyName
- 設定するプロパティの名前
setValueIfAttributeDefined
public static void setValueIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。プロパティ名は、小文字のハイフンで区切られた属性に相当するキャメルケースの名前になります(たとえば、"foo-bar" 属性は "fooBar" プロパティと一致します)。
- パラメーター:
builder
- 構成する Bean 定義ビルダーelement
- - 属性を定義する必要がある XML 要素attributeName
- - プロパティに値が設定される属性の名前- 関連事項:
setValueIfAttributeDefined
public static void setValueIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName, boolean emptyStringAllowed) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。- パラメーター:
builder
- 構成する Bean 定義ビルダーelement
- 属性を定義する必要がある XML 要素attributeName
- プロパティの入力に使用される値を持つ属性の名前propertyName
- 設定するプロパティの名前emptyStringAllowed
- -true の場合、空の文字列("")でも値が設定されます。false の場合、空の文字列は、属性が提供されなかったかのように扱われます。
setValueIfAttributeDefined
public static void setValueIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, boolean emptyStringAllowed) 提供された Bean 定義ビルダーを、その属性が指定された要素で定義されている場合に名前が指定された属性に対応するプロパティ値で構成します。プロパティ名は、小文字のハイフンで区切られた属性に相当するキャメルケースの名前になります(たとえば、"foo-bar" 属性は "fooBar" プロパティと一致します)。
- パラメーター:
builder
- 構成する Bean 定義ビルダーelement
- - 属性を定義する必要がある XML 要素attributeName
- - プロパティに値が設定される属性の名前emptyStringAllowed
- -true の場合、空の文字列("")でも値が設定されます。false の場合、空の文字列は、属性が提供されなかったかのように扱われます。- 関連事項:
setReferenceIfAttributeDefined
public static void setReferenceIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName) 提供されている Bean 定義ビルダーを、Bean へのプロパティ参照で構成します。Bean 参照は、その属性が指定された要素で定義されている場合に、名前が指定されている属性の値によって識別されます。- パラメーター:
builder
- 構成する Bean 定義ビルダーelement
- 属性を定義する必要がある XML 要素attributeName
- プロパティを設定するための Bean 参照として使用される値を持つ属性の名前propertyName
- 設定するプロパティの名前
setReferenceIfAttributeDefined
public static void setReferenceIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, StringSE propertyName, boolean emptyStringAllowed) setReferenceIfAttributeDefined
public static void setReferenceIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName) 提供されている Bean 定義ビルダーを、Bean へのプロパティ参照で構成します。Bean 参照は、その属性が指定された要素で定義されている場合に、名前が指定されている属性の値によって識別されます。プロパティ名は、小文字のハイフンで区切られた属性に相当するキャメルケースの名前になります(たとえば、"foo-bar" 属性は "fooBar" プロパティと一致します)。
- パラメーター:
builder
- 構成する Bean 定義ビルダーelement
- - 属性を定義する必要がある XML 要素attributeName
- - プロパティを設定するための Bean 参照として使用される値を持つ属性の名前- 関連事項:
setReferenceIfAttributeDefined
public static void setReferenceIfAttributeDefined(BeanDefinitionBuilder builder, ElementSE element, StringSE attributeName, boolean emptyStringAllowed) createElementDescription
ノード名に基づいて要素のわかりやすい説明を提供します。使用可能な場合は、"id" 属性値も提供します。これは、Bean 定義パーサー内からエラーメッセージを作成できます。- パラメーター:
element
- 要素。- 戻り値:
- 説明。
configurePollerMetadata
public static void configurePollerMetadata(ElementSE pollerElement, BeanDefinitionBuilder targetBuilder, ParserContext parserContext) "poller" 要素を解析して、ターゲット BeanDefinitionBuilder の参照を提供します。ポーラー要素に "ref" 属性が含まれていない場合、これにより PollerMetadata インスタンスが作成および登録され、ターゲットビルダーのプロパティ参照として追加されます。- パラメーター:
pollerElement
- 解析する "poller" 要素targetBuilder
- 「トリガー」プロパティを期待するビルダーparserContext
- ターゲットビルダーの parserContext
getTextFromAttributeOrNestedElement
public static StringSE getTextFromAttributeOrNestedElement(ElementSE element, StringSE name, ParserContext parserContext) 名前付き属性が存在する場合は、それからテキスト値を取得します。それ以外の場合は、同じ名前のネストされた要素を確認します。両方が指定されている場合はエラーになりますが、どちらも指定されていない場合は null を返します。- パラメーター:
element
- DOM ノードname
- プロパティの名前 (属性または子要素)parserContext
- 現在のコンテキスト- 戻り値:
- 属性または要素からのテキストまたは null
parseInnerHandlerDefinition
public static BeanComponentDefinition parseInnerHandlerDefinition(ElementSE element, ParserContext parserContext) configureHeaderMapper
public static void configureHeaderMapper(ElementSE element, BeanDefinitionBuilder rootBuilder, ParserContext parserContext, ClassSE<?> headerMapperClass, StringSE replyHeaderValue) 受信および送信チャネルアダプター / ゲートウェイ用に HeaderMapper を構成するためのユーティリティメソッド。- パラメーター:
element
- 要素。rootBuilder
- ルートビルダー。parserContext
- パーサーコンテキスト。headerMapperClass
- ヘッダーマッパークラス。replyHeaderValue
- 応答ヘッダー値。
configureHeaderMapper
public static void configureHeaderMapper(ElementSE element, BeanDefinitionBuilder rootBuilder, ParserContext parserContext, BeanDefinitionBuilder headerMapperBuilder, @Nullable StringSE replyHeaderValueArg) 受信および送信チャネルアダプター / ゲートウェイ用に HeaderMapper を構成するためのユーティリティメソッド。- パラメーター:
element
- 要素。rootBuilder
- ルートビルダー。parserContext
- パーサーコンテキスト。headerMapperBuilder
- ヘッダーマッパービルダー。replyHeaderValueArg
- 応答ヘッダー値。
configureTransactionAttributes
"transactional" 要素を解析し、"transactionManager" およびその他の "transactionDefinition" プロパティを使用してTransactionInterceptor
を構成します。例: このアドバイザーは、ポーリングタスクプロキシに適用されます。- パラメーター:
txElement
- トランザクション要素。- 戻り値:
- Bean 定義。
- 関連事項:
configureTransactionAttributes
public static BeanDefinition configureTransactionAttributes(ElementSE txElement, boolean handleMessageAdvice) "transactional" 要素を解析し、"transactionManager" およびその他の "transactionDefinition" プロパティを使用してTransactionInterceptor
またはTransactionHandleMessageAdvice
を構成します。例: このアドバイザーは、ポーリングタスクプロキシに適用されます。- パラメーター:
txElement
- トランザクション要素。handleMessageAdvice
-TransactionHandleMessageAdvice
または通常のTransactionInterceptor
を使用するかどうかのフラグ- 戻り値:
- Bean 定義。
- 関連事項:
configureTransactionDefinition
"transactional" 要素の属性を解析し、提供された "transactionDefinition" プロパティを使用してDefaultTransactionAttribute
を構成します。- パラメーター:
txElement
- トランザクション要素。- 戻り値:
- Bean 定義。
generateAlias
configureAndSetAdviceChainIfPresent
public static void configureAndSetAdviceChainIfPresent(ElementSE adviceChainElement, ElementSE txElement, BeanDefinition parentBeanDefinition, ParserContext parserContext) configureAndSetAdviceChainIfPresent
public static void configureAndSetAdviceChainIfPresent(ElementSE adviceChainElement, ElementSE txElement, boolean handleMessageAdvice, BeanDefinition parentBeanDefinition, ParserContext parserContext) configureAndSetAdviceChainIfPresent
public static void configureAndSetAdviceChainIfPresent(ElementSE adviceChainElement, ElementSE txElement, BeanDefinition parentBeanDefinition, ParserContext parserContext, StringSE propertyName) configureAndSetAdviceChainIfPresent
public static void configureAndSetAdviceChainIfPresent(ElementSE adviceChainElement, ElementSE txElement, boolean handleMessageAdvice, BeanDefinition parentBeanDefinition, ParserContext parserContext, StringSE propertyName) configureAdviceChain
public static ManagedList configureAdviceChain(ElementSE adviceChainElement, ElementSE txElement, BeanDefinition parentBeanDefinition, ParserContext parserContext) configureAdviceChain
public static ManagedList configureAdviceChain(ElementSE adviceChainElement, ElementSE txElement, boolean handleMessageAdvice, BeanDefinition parentBeanDefinition, ParserContext parserContext) createExpressionDefinitionFromValueOrExpression
public static BeanDefinition createExpressionDefinitionFromValueOrExpression(StringSE valueElementName, StringSE expressionElementName, ParserContext parserContext, ElementSE element, boolean oneRequired) createExpressionDefIfAttributeDefined
public static BeanDefinition createExpressionDefIfAttributeDefined(StringSE expressionElementName, ElementSE element) createDirectChannel
checkAndConfigureFixedSubscriberChannel
public static void checkAndConfigureFixedSubscriberChannel(ElementSE element, ParserContext parserContext, StringSE channelName, StringSE handlerBeanName) injectPropertyWithAdapter
public static void injectPropertyWithAdapter(StringSE beanRefAttribute, StringSE methodRefAttribute, StringSE expressionAttribute, StringSE beanProperty, StringSE adapterClass, ElementSE element, BeanDefinitionBuilder builder, BeanMetadataElement processor, ParserContext parserContext) injectConstructorWithAdapter
public static void injectConstructorWithAdapter(StringSE beanRefAttribute, StringSE methodRefAttribute, StringSE expressionAttribute, StringSE adapterClass, ElementSE element, BeanDefinitionBuilder builder, BeanMetadataElement processor, ParserContext parserContext)