MetaDone
|
Public Member Functions | |
AbstractSubscription (Class< T > cl, MapFct<?super T, Boolean > predicate) | |
abstract S | getSubscriber () |
final Class< T > | getUsedClass () |
MapFct<?super T, Boolean > | getPredicate () |
void | setPredicate (MapFct<?super T, Boolean > predicate) |
EventTower<?super T > | getUsedManager () |
AbstractSubscription< T, S > | setManager (EventTower<?super T > manager) |
boolean | isSubscribed () |
void | subscribe () |
void | unsubscribe () |
String | toString () |
Protected Member Functions | |
void | finalize () throws Throwable |
Private Attributes | |
final Class< T > | cl |
MapFct<?super T, Boolean > | predicate |
EventTower<?super T > | manager |
boolean | subscribed |
A base class for subscriptions.
Represents a subscriber with a manager and classes.
<T> | The class to which to subscribe |
<S> | The subscriber type |
metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.AbstractSubscription | ( | Class< T > | cl, |
MapFct<?super T, Boolean > | predicate | ||
) |
Initializes this subscription.
subscriber | The subscriber |
cl | The class |
predicate | The predicate |
NullPointerException | when subscriber or cl is null |
void metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.finalize | ( | ) | throws Throwable [protected] |
MapFct<? super T, Boolean> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.getPredicate | ( | ) |
Gets the predicate.
null
) abstract S metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.getSubscriber | ( | ) | [pure virtual] |
Gets the subscriber.
final Class<T> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.getUsedClass | ( | ) |
Gets the used class.
EventTower<? super T> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.getUsedManager | ( | ) |
Gets the manager.
null
) boolean metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.isSubscribed | ( | ) |
Indicates whether the subscribe(EventTower) has been executed.
true
if subscribed AbstractSubscription<T, S> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.setManager | ( | EventTower<?super T > | manager | ) |
Sets the manager.
If the subscription is subscribed, it will be firstly unsubscribed.
manager | The new manager (may be null |
void metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.setPredicate | ( | MapFct<?super T, Boolean > | predicate | ) |
Sets the predicate.
predicate | The new predicate or null |
void metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.subscribe | ( | ) |
Subscribes to the manager.
String metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.toString | ( | ) |
void metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.unsubscribe | ( | ) |
Unsubscribes from the manager.
final Class<T> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.cl [private] |
EventTower<? super T> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.manager [private] |
MapFct<? super T, Boolean> metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.predicate [private] |
boolean metadone.publish_subscribe.AbstractSubscription< T, S extends Subscriber<?super T > >.subscribed [private] |