T
- リスナーの型 public class ServletListenerRegistrationBean<T extends EventListenerSE> extends RegistrationBean
EventListener
SE を登録する ServletContextInitializer
。ServletContext
EE によって提供される registration
EE 機能に似ていますが、Spring Bean フレンドリーな設計です。この Bean を使用して、次の型のリスナーを登録できます。HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
コンストラクターと説明 |
---|
ServletListenerRegistrationBean() 新しい ServletListenerRegistrationBean インスタンスを作成します。 |
ServletListenerRegistrationBean(T listener) 新しい ServletListenerRegistrationBean インスタンスを作成します。 |
修飾子と型 | メソッドと説明 |
---|---|
protected StringSE | getDescription() 登録の説明を返します。 |
T | getListener() 登録するリスナーを返します。 |
static SetSE<ClassSE<?>> | getSupportedTypes() この登録でサポートされている型を返します。 |
static boolean | isSupportedType(EventListenerSE listener) 指定されたリスナーがサポートされている型の 1 つである場合、 true を返します。 |
protected void | register(StringSE description, ServletContextEE servletContext) この Bean をサーブレットコンテキストに登録します。 |
void | setListener(T listener) 登録するリスナーを設定します。 |
getOrder, isEnabled, onStartup, setEnabled, setOrder
cloneSE, equalsSE, finalizeSE, getClassSE, hashCodeSE, notifySE, notifyAllSE, toStringSE, waitSE, waitSE, waitSE
public ServletListenerRegistrationBean()
ServletListenerRegistrationBean
インスタンスを作成します。public ServletListenerRegistrationBean(T listener)
ServletListenerRegistrationBean
インスタンスを作成します。listener
- 登録するリスナー public void setListener(T listener)
listener
- 登録するリスナー public T getListener()
protected StringSE getDescription()
RegistrationBean
RegistrationBean
の getDescription
protected void register(StringSE description, ServletContextEE servletContext)
RegistrationBean
RegistrationBean
の register
description
- 登録されているアイテムの説明 servletContext
- サーブレットコンテキスト public static boolean isSupportedType(EventListenerSE listener)
true
を返します。listener
- テストするリスナー