クラス AbstractRequestMatcherRegistry<C>
- 型パラメーター:
C- RequestMatcher の作成後に返される、またはチェーンされるオブジェクト
- 既知の直属サブクラス
AbstractConfigAttributeRequestMatcherRegistry、AuthorizeHttpRequestsConfigurer.AuthorizationManagerRequestMatcherRegistry、HttpSecurity.RequestMatcherConfigurer、WebSecurity.IgnoredRequestConfigurer
RequestMatcher を登録するための基本クラス。例: 特定のレベルの認可が必要な RequestMatcher を指定できる場合があります。- 導入:
- 3.2
コンストラクターの概要
コンストラクターメソッドのサマリー
修飾子と型メソッド説明リクエストをマッピングします。protected abstract CchainRequestMatchers(ListSE<RequestMatcher> requestMatchers) サブクラスは、RequestMatcherインスタンスの作成にチェーンされたオブジェクトを返すためにこのメソッドを実装する必要があります。protected final ListSE<MvcRequestMatcher>createMvcMatchers(org.springframework.http.HttpMethod method, StringSE... mvcPatterns) 渡されたメソッドとパターンのMvcRequestMatcherインスタンスを作成しますdispatcherTypeMatchers(jakarta.servlet.DispatcherType... dispatcherTypes) dispatcherTypeMatchers(org.springframework.http.HttpMethod method, jakarta.servlet.DispatcherType... dispatcherTypes) DispatcherTypeRequestMatcherインスタンスのListSE をマップします。protected final org.springframework.context.ApplicationContextApplicationContextを取得しますrequestMatchers(StringSE... patterns) requestMatchers(org.springframework.http.HttpMethod method) requestMatchers(org.springframework.http.HttpMethod method, StringSE... patterns) requestMatchers(RequestMatcher... requestMatchers) RequestMatcherインスタンスのリストをAbstractRequestMatcherRegistryに関連付けますprotected final voidsetApplicationContext(org.springframework.context.ApplicationContext context)
コンストラクターの詳細
AbstractRequestMatcherRegistry
public AbstractRequestMatcherRegistry()
メソッドの詳細
setApplicationContext
protected final void setApplicationContext(org.springframework.context.ApplicationContext context) getApplicationContext
protected final org.springframework.context.ApplicationContext getApplicationContext()ApplicationContextを取得します- 戻り値:
ApplicationContext
anyRequest
リクエストをマッピングします。- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト
createMvcMatchers
protected final ListSE<MvcRequestMatcher> createMvcMatchers(org.springframework.http.HttpMethod method, StringSE... mvcPatterns) 渡されたメソッドとパターンのMvcRequestMatcherインスタンスを作成します- パラメーター:
method- 使用する HTTP メソッド、または使用する必要がある場合は nullmvcPatterns- 一致する Spring MVC パターン- 戻り値:
MvcRequestMatcherインスタンスのリスト
dispatcherTypeMatchers
public C dispatcherTypeMatchers(@Nullable org.springframework.http.HttpMethod method, jakarta.servlet.DispatcherType... dispatcherTypes) DispatcherTypeRequestMatcherインスタンスのListSE をマップします。- パラメーター:
method- 使用するHttpMethodまたは任意のHttpMethodのnulldispatcherTypes- 照合するディスパッチャー型- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト
dispatcherTypeMatchers
- パラメーター:
dispatcherTypes- 照合するディスパッチャー型- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト
requestMatchers
RequestMatcherインスタンスのリストをAbstractRequestMatcherRegistryに関連付けます- パラメーター:
requestMatchers-RequestMatcherインスタンス- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト
requestMatchers
HandlerMappingIntrospectorがクラスパスで使用可能な場合、一致する特定のHttpMethodも指定するMvcRequestMatcherにマップされます。このマッチャーは、Spring MVC がマッチングに使用するのと同じルールを使用します。例: 多くの場合、パス "/path" のマッピングは、"/path","/path/","/path.html" などで一致します。HandlerMappingIntrospectorが使用できない場合は、AntPathRequestMatcherにマップします。特定の
RequestMatcherを指定する必要がある場合は、代わりにrequestMatchers(RequestMatcher...)を使用してください- パラメーター:
method- 使用するHttpMethodまたは任意のHttpMethodのnullpatterns- 一致するパターン。MvcRequestMatcherが使用されている場合、マッチングのルールは Spring MVC によって定義されます。- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト- 導入:
- 5.8
requestMatchers
HandlerMappingIntrospectorがクラスパスで使用可能な場合、どのHttpMethodが使用されているかを気にしないMvcRequestMatcherにマップされます。このマッチャーは、Spring MVC がマッチングに使用するのと同じルールを使用します。例: 多くの場合、パス "/path" のマッピングは、"/path","/path/","/path.html" などで一致します。HandlerMappingIntrospectorが使用できない場合は、AntPathRequestMatcherにマップします。特定の
RequestMatcherを指定する必要がある場合は、代わりにrequestMatchers(RequestMatcher...)を使用してください- パラメーター:
patterns- 一致するパターン。MvcRequestMatcherが使用されている場合、マッチングのルールは Spring MVC によって定義されます。- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト- 導入:
- 5.8
requestMatchers
HandlerMappingIntrospectorがクラスパスで使用可能な場合、特定のHttpMethodで一致するMvcRequestMatcherにマップされます。このマッチャーは、Spring MVC がマッチングに使用するのと同じルールを使用します。例: 多くの場合、パス "/path" のマッピングは、"/path","/path/","/path.html" などで一致します。HandlerMappingIntrospectorが使用できない場合は、AntPathRequestMatcherにマップします。特定の
RequestMatcherを指定する必要がある場合は、代わりにrequestMatchers(RequestMatcher...)を使用してください- パラメーター:
method- 使用するHttpMethodまたは任意のHttpMethodのnull- 戻り値:
RequestMatcherの作成後にチェーンされるオブジェクト- 導入:
- 5.8
chainRequestMatchers
サブクラスは、RequestMatcherインスタンスの作成にチェーンされたオブジェクトを返すためにこのメソッドを実装する必要があります。- パラメーター:
requestMatchers- 作成されたRequestMatcherインスタンス- 戻り値:
RequestMatcherへの何かの関連付けを可能にするサブクラスのチェーンオブジェクト