dk.rode.thesis.observer
Interface AspectObservableSequence<O,A,E>
- Type Parameters:
O
- The type of observers.A
- The type of aspect used by this sequence to register and
notify observers.E
- The type of values delivered by this observable sequence.
- All Superinterfaces:
- AspectObservable<O,A>, Copyable<Sequence<E>>, Observable<O>, ObservableSequence<O,A,E>, Sequence<E>, SequenceObserver<A>, StrictCopyable<Sequence<E>>, Stringable<Sequence<E>>
- All Known Implementing Classes:
- DateSequence, SequenceObserversSequence, SequenceObserversSequenceDecorator
@Participant(value={"Subject","Observer"})
public interface AspectObservableSequence<O,A,E>
- extends AspectObservable<O,A>, ObservableSequence<O,A,E>
An aspect observable sequence is a sequence that allows for
observers of the type supplied as the type parameter
O
to subscribe to specific sequence aspect values and
be notified when the sequence changes its aspect to such a
value. The type of aspect is determined by the type parameter A
.
The notification of observers is performed by invoking the
SequenceObserver.sequenceEvent(Sequence, Object)
method with this sequence as the first argument and the aspect
of this sequence as the second. This will normally be handled
by the implementing sequence itself, but how individual observers
are notified must be implemented by the sub-class as it is
dependent on the type of O
. Only observers subscribing
the the given aspect will be notified.
The order in which observers are notified is undefined.
- Author:
- Gunni Rode / rode.dk
- See Also:
ObservableSequence
Feel free to use and/or modify the Java 6 source code developed for this thesis AT YOUR OWN RISK, but note that the source code comes WITHOUT ANY — and I do mean WITHOUT ANY — form of warranty WHAT SO EVER!
The original thesis and source code are available at rode.dk/thesis.