java.util
클래스 EventListenerProxy
java.lang.Object
java.util.EventListenerProxy
- 모든 구현된 인터페이스:
- EventListener
- 직계의 기존의 서브 클래스:
- AWTEventListenerProxy , PropertyChangeListenerProxy , VetoableChangeListenerProxy
public abstract class EventListenerProxy
- extends Object
- implements EventListener
추가 파라미터세트를 청취자에게 관련짓는, EventListener 클래스의 abstract 래퍼 클래스. 서브 클래스는, 부가적 인수 또는 파라미터에 storage 메소드와 accessor 메소드를 제공할 필요가 있습니다.
지정된 프로퍼티을 그 청취자에게 관련시키는 한 수단으로서 getListeners() 메소드를 사용해 EventListerProxy 의 서브 클래스를 돌려줄 수가 있습니다.
예를 들어, 지정된 프로퍼티을 지원하는 Bean 에는, 다음과 같이 프로퍼티의 PropertyChangeListener 를 추가하는 2 개의 인수 메소드의 시그니챠가 있습니다.
public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener);
Bean 가 0 인수나 구현하는 경우, 다음과 같이 청취자 메소드를 가져옵니다.
public PropertyChangeListener[] getPropertyChangeListeners();
배열에는, PropertyChangeListenerProxy 객체이기도 한 내부의 PropertyChangeListeners 를 포함할 수도 있습니다.
호출 메소드가 지정된 프로퍼티을 꺼내고 싶은 경우, 요소가 프록시 클래스인가 어떤가를 확인하기 위해서 요소를 검사할 필요가 있습니다.
- 도입된 버젼:
- 1.4
클래스 java.lang. Object 로부터 상속된 메소드 |
clone , equals , finalize , getClass , hashCode , notify , notifyAll , toString , wait , wait , wait |
EventListenerProxy
public EventListenerProxy(EventListener listener)
- 파라미터:
listener
- 청취자 객체
getListener
public EventListener getListener()
- 반환값:
- 이 프록시에 관련한 청취자입니다.
버그의 보고와 기능의 요청
한층 더 자세한 API 레퍼런스 및 개발자 문서에 대해서는,Java SE 개발자용 문서를 참조해 주세요. 개발자전용의 상세한 해설, 개념의 개요, 용어의 정의, 버그의 회피책, 및 코드 실례가 포함되어 있습니다. Copyright 2006 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms . Documentation Redistribution Policy 도 참조해 주세요.