java::awt::event::ComponentSource Class Reference

Inheritance diagram for java::awt::event::ComponentSource:

Inheritance graph
java::awt::Componentjava::util::EventSourcejava::lang::Interfacejava::lang::ScopeAdapterjava::lang::Objectjava::lang::Syncjava::lang::Lockjava::awt::Buttonjava::awt::Canvasjava::awt::Checkboxjava::awt::Choicejava::awt::Containerjava::awt::Labeljava::awt::ListBoxjava::awt::Scrollbarjava::awt::TextComponentjava::awt::Paneljava::awt::Windowjava::awt::Dialogjava::awt::Framejava::awt::TextAreajava::awt::TextField
[legend]
Collaboration diagram for java::awt::event::ComponentSource:

Collaboration graph
java::util::EventSourcejava::lang::Interfacejava::lang::ScopeAdapterjava::lang::Comparablejava::util::Collectionjava::lang::Objectjava::lang::ObjectRefjava::lang::Syncjava::lang::Lockjava::util::LinkedListjava::util::AbstractSequentialListjava::util::AbstractListjava::util::AbstractCollectionjava::util::List
[legend]

List of all members.


Detailed Description

The source abstract object for component event sources.

The class that is interested in broadcast an component event extends this object.

See also:
ComponentEvent

ComponentListener

Author:
Yuh-Jye Chang
Version:
1.0 07/19/04

Public Member Functions

virtual void addComponentListener (const Ref< ComponentListener > l)
 Adds a listener to receive component events.
virtual void removeComponentListener (const Ref< ComponentListener > l)
 Remove an component listener.
virtual jboolean hasComponentListeners () const
 Indicate there are listeners registered.
virtual Ref< ListgetComponentListeners () const
 Returns a list of all the component listeners registered.
virtual void processComponentEvent (const ComponentEvent &e)
 Brodcast the event to all the registered component listeners.

Protected Attributes

LinkedList listeners
 REGISTER_MEMBERS

Member Function Documentation

virtual void java::awt::event::ComponentSource::addComponentListener ( const Ref< ComponentListener l  )  [virtual]

Adds a listener to receive component events.

Parameters:
l the listener to receive events
See also:
ComponentEvent

virtual void java::awt::event::ComponentSource::removeComponentListener ( const Ref< ComponentListener l  )  [virtual]

Remove an component listener.

Parameters:
l the listener being removed
See also:
ComponentEvent

virtual jboolean java::awt::event::ComponentSource::hasComponentListeners (  )  const [virtual]

Indicate there are listeners registered.

virtual Ref<List> java::awt::event::ComponentSource::getComponentListeners (  )  const [virtual]

Returns a list of all the component listeners registered.

Returns:
all ComponentListeners or an empty list if no component listeners are currently registered
See also:
addComponentListener

removeComponentListener

virtual void java::awt::event::ComponentSource::processComponentEvent ( const ComponentEvent e  )  [virtual]

Brodcast the event to all the registered component listeners.

Parameters:
e the Component Event being brocasted
See also:
ComponentEvent


Member Data Documentation

LinkedList java::awt::event::ComponentSource::listeners [protected]

java::awt::event::ComponentSource::REGISTER_MEMBERS [protected]

Reimplemented from java::lang::Sync.

Reimplemented in java::awt::Button, java::awt::Canvas, java::awt::Checkbox, java::awt::Choice, java::awt::Dialog, java::awt::Frame, java::awt::Label, java::awt::ListBox, java::awt::Panel, java::awt::TextArea, and java::awt::TextField.


The documentation for this class was generated from the following file:
Generated on Fri May 16 11:56:15 2008 for CrossPlatformJavaLikeC++API by  doxygen 1.5.3