- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- java.util.AbstractList<E>
-
- java.util.ArrayList<Listener>
-
- de.haumacher.msgbuf.observer.Listener.MultiplexListener
-
- All Implemented Interfaces:
Listener,Serializable,Cloneable,Iterable<Listener>,Collection<Listener>,List<Listener>,RandomAccess
- Enclosing interface:
- Listener
public static final class Listener.MultiplexListener extends ArrayList<Listener> implements Listener
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface de.haumacher.msgbuf.observer.Listener
Listener.MultiplexListener
-
-
Field Summary
-
Fields inherited from class java.util.AbstractList
modCount
-
-
Constructor Summary
Constructors Constructor Description MultiplexListener(Listener a, Listener b)Creates aListener.MultiplexListener.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidafterChanged(Observable obj, String property)Informs thisListenerthat the property of an element was changed.voidafterRemove(Observable obj, String property, int index, Object element)Informs thisListenerthat an element was removed from a repeated property with the given name.voidbeforeAdd(Observable obj, String property, int index, Object element)Informs thisListenerthat an element will be added to the repeated property with the given name.voidbeforeSet(Observable obj, String property, Object value)Informs thisListenerthat the value of the given property is to be modified.Listenerregister(Listener l)Listenerunregister(Listener removed)-
Methods inherited from class java.util.ArrayList
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, equals, forEach, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSize
-
Methods inherited from class java.util.AbstractCollection
containsAll, toString
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, stream, toArray
-
Methods inherited from interface java.util.List
containsAll
-
Methods inherited from interface de.haumacher.msgbuf.observer.Listener
afterRemove, beforeAdd
-
-
-
-
Constructor Detail
-
MultiplexListener
public MultiplexListener(Listener a, Listener b)
Creates aListener.MultiplexListener.
-
-
Method Detail
-
beforeSet
public void beforeSet(Observable obj, String property, Object value)
Description copied from interface:ListenerInforms thisListenerthat the value of the given property is to be modified.- Specified by:
beforeSetin interfaceListener- Parameters:
obj- TheObservableobject.property- The name of the property to be modified.value- The new value that is being set to the given property.
-
beforeAdd
public void beforeAdd(Observable obj, String property, int index, Object element)
Description copied from interface:ListenerInforms thisListenerthat an element will be added to the repeated property with the given name.- Specified by:
beforeAddin interfaceListener- Parameters:
obj- TheObservableobject.property- The name of the property to be modified.index- The index where the new element will be added if the property is ordered,-1otherwise.element- The new element that is being added to the given property.
-
afterRemove
public void afterRemove(Observable obj, String property, int index, Object element)
Description copied from interface:ListenerInforms thisListenerthat an element was removed from a repeated property with the given name.- Specified by:
afterRemovein interfaceListener- Parameters:
obj- TheObservableobject.property- The name of the property to be modified.index- The index where the element was removed if the property is ordered,-1otherwise.element- The element that was removed from the given property.
-
afterChanged
public void afterChanged(Observable obj, String property)
Description copied from interface:ListenerInforms thisListenerthat the property of an element was changed.This method is also called after all other methods to indicate that a property has been changed. It is not called more than once for bulk operations (e.g. adding several objects to a list)
- Specified by:
afterChangedin interfaceListener- Parameters:
obj- TheObservableobject.property- The name of the property to be modified.
-
-