fr.ove.applet
Class AListenableAppletListener

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjava.awt.Panel
              extended byjava.applet.Applet
                  extended byfr.ove.applet.AppletLoadingChecked
                      extended byfr.ove.applet.AListenableAppletListener
All Implemented Interfaces:
javax.accessibility.Accessible, AppletListener, java.util.EventListener, java.awt.image.ImageObserver, ListenableApplet, java.awt.MenuContainer, java.io.Serializable

public final class AListenableAppletListener
extends AppletLoadingChecked
implements ListenableApplet, AppletListener

This is an implementation of the ListenableApplet and AppletListener interfaces.
This applet takes as argument a parameter named name which represents the name the instance to identify it for futher treatments and for registration.
Maintains a list of listeners (AppletListener) of the instance and fires to them an event (AppletEvent) for each change. It also takes as argument a parameter named listened which represents a list of ListenableApplet the instance will be listening to.
Each element of the list is the name of the corresponding ListenableApplet.

This class is an final class, so it can't be overloaded.

Version:
1.0 30/04/99
Author:
© 1999 DIRAT Laurent
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class java.applet.Applet
java.applet.Applet.AccessibleApplet
 
Nested classes inherited from class java.awt.Panel
java.awt.Panel.AccessibleAWTPanel
 
Nested classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
 
Fields inherited from class fr.ove.applet.AppletLoadingChecked
ERROR, JDK11_NOT_SUPPORTED, LOADED, LOADING
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
AListenableAppletListener()
           
 
Method Summary
 void addAppletListener(AppletListener appletListener)
          Registers a listener of the instance.
 void consumeAppletEvent(AppletEvent appletEvent)
          Consumes (i.e. treats) the event received.
 void fireAppletEvent(AppletEvent appletEvent)
          Fires an event to all the registered listeners of the instance.
 java.lang.String getName()
          Returns the name of the applet.
 void init()
          Initialyzes the instance by registering it to each ListenableApplet in the list passed as argument.
 void removeAppletListener(AppletListener appletListener)
          Unregisters the specified listener of the instance.
 void setName(java.lang.String name)
          Sets the name of the applet.
 
Methods inherited from class fr.ove.applet.AppletLoadingChecked
getState, getTheApplet, paint, setState, start, stop, update
 
Methods inherited from class java.applet.Applet
destroy, getAccessibleContext, getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus
 
Methods inherited from class java.awt.Panel
addNotify
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, paramString, preferredSize, print, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, removeNotify, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFont, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isOpaque, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AListenableAppletListener

public AListenableAppletListener()
Method Detail

init

public void init()
Initialyzes the instance by registering it to each ListenableApplet in the list passed as argument.

Overrides:
init in class AppletLoadingChecked

setName

public void setName(java.lang.String name)
Sets the name of the applet.

Specified by:
setName in interface ListenableApplet
Parameters:
name - the name of the applet.

getName

public java.lang.String getName()
Returns the name of the applet.

Specified by:
getName in interface ListenableApplet

addAppletListener

public void addAppletListener(AppletListener appletListener)
Registers a listener of the instance.

Specified by:
addAppletListener in interface ListenableApplet

removeAppletListener

public void removeAppletListener(AppletListener appletListener)
Unregisters the specified listener of the instance.

Specified by:
removeAppletListener in interface ListenableApplet
Parameters:
appletListener - the listener to remove.

fireAppletEvent

public void fireAppletEvent(AppletEvent appletEvent)
Fires an event to all the registered listeners of the instance.

Specified by:
fireAppletEvent in interface ListenableApplet
Parameters:
appletEvent - the event to fire.

consumeAppletEvent

public void consumeAppletEvent(AppletEvent appletEvent)
Consumes (i.e. treats) the event received.

Specified by:
consumeAppletEvent in interface AppletListener


Copyright © 1999-2007 Universit?© de Nice Sophia-Antipolis, I3S, Ove SARL, DFKI and Universit?§t des Saarlandes. All Rights Reserved.