public abstract class AbstractDialLayer extends java.lang.Object implements DialLayer
DialLayer. It includes
an event notification mechanism.| Modifier and Type | Field and Description |
|---|---|
private javax.swing.event.EventListenerList |
listenerList
Storage for registered listeners.
|
private boolean |
visible
A flag that controls whether or not the layer is visible.
|
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractDialLayer()
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addChangeListener(DialLayerChangeListener listener)
Registers an object for notification of changes to the dial layer.
|
java.lang.Object |
clone()
Returns a clone of this instance.
|
boolean |
equals(java.lang.Object obj)
Tests this instance for equality with an arbitrary object.
|
int |
hashCode()
Returns a hash code for this instance.
|
boolean |
hasListener(java.util.EventListener listener)
Returns
true if the specified object is registered with
the dataset as a listener. |
boolean |
isVisible()
Returns
true if this layer is visible (should be displayed),
and false otherwise. |
protected void |
notifyListeners(DialLayerChangeEvent event)
Notifies all registered listeners that the dial layer has changed.
|
private void |
readObject(java.io.ObjectInputStream stream)
Provides serialization support.
|
void |
removeChangeListener(DialLayerChangeListener listener)
Deregisters an object for notification of changes to the dial layer.
|
void |
setVisible(boolean visible)
Sets the flag that determines whether or not this layer is drawn by
the plot, and sends a
DialLayerChangeEvent to all registered
listeners. |
finalize, getClass, notify, notifyAll, toString, wait, wait, waitdraw, isClippedToWindowprivate boolean visible
private transient javax.swing.event.EventListenerList listenerList
public boolean isVisible()
true if this layer is visible (should be displayed),
and false otherwise.isVisible in interface DialLayersetVisible(boolean)public void setVisible(boolean visible)
DialLayerChangeEvent to all registered
listeners.visible - the flag.isVisible()public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - the object (null permitted).public int hashCode()
hashCode in class java.lang.Objectpublic java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone in class java.lang.Objectjava.lang.CloneNotSupportedException - if there is a problem cloning this
instance.public void addChangeListener(DialLayerChangeListener listener)
addChangeListener in interface DialLayerlistener - the object that is being registered.removeChangeListener(DialLayerChangeListener)public void removeChangeListener(DialLayerChangeListener listener)
removeChangeListener in interface DialLayerlistener - the object to deregister.addChangeListener(DialLayerChangeListener)public boolean hasListener(java.util.EventListener listener)
true if the specified object is registered with
the dataset as a listener. Most applications won't need to call this
method, it exists mainly for use by unit testing code.hasListener in interface DialLayerlistener - the listener.protected void notifyListeners(DialLayerChangeEvent event)
DialLayerChangeEvent provides information about the change.event - information about the change to the axis.private void readObject(java.io.ObjectInputStream stream)
throws java.io.IOException,
java.lang.ClassNotFoundException
stream - the input stream.java.io.IOException - if there is an I/O error.java.lang.ClassNotFoundException - if there is a classpath problem.