T - public class ReceivesPrioritizedValue<T> extends ReceivesMultiValue<T>
ReceivesMultiValue which uses three prioritized callback buckets.
#addPre(ReceivesValue, boolean) -
pushes callback onto stack called before all others.
Send true to push on head of pre stack
addPost(ReceivesValue) -
pushes callback onto bottom of the stack called after all others.
Send true to push on head of pre stack
#addToHead(ReceivesValue) -
push callback on top of main callback stack
ReceivesMultiValue.addReceiver(ReceivesValue) -
push callback on bottom of main callback stack
ReceivesValue.NoOp<T>| Constructor and Description |
|---|
ReceivesPrioritizedValue() |
| Modifier and Type | Method and Description |
|---|---|
void |
addPost(ReceivesValue<T> receiver)
Adds a callback that will be fired after the pre and main callback stacks
|
void |
addPre(ReceivesValue<T> receiver)
Adds a callback that will be fired before the main and post callback stacks
|
void |
clearReceivers()
Clear all callback stacks.
|
void |
removeReceiver(ReceivesValue<T> receiver)
Explicitly remove the given receiver from all callback stacks.
|
void |
set(T value)
Send an object to all of our callbacks, in prioritized order.
|
addReceiverpublic void addPre(ReceivesValue<T> receiver)
receiver - - The receiver to add to pre-fire stacktop - - true to unshift onto head, false to push onto tailpublic void addPost(ReceivesValue<T> receiver)
receiver - - The receiver to add to pre-fire stacktop - - true to unshift onto head, false to push onto tailpublic void set(T value)
set in interface ReceivesValue<T>set in class ReceivesMultiValue<T>value - - The object to receive.public void clearReceivers()
clearReceivers in class ReceivesMultiValue<T>public void removeReceiver(ReceivesValue<T> receiver)
removeReceiver in class ReceivesMultiValue<T>receiver - - The receiver to remove.Copyright © December 07, 2012–2015 The Internet Party. All rights reserved.