public abstract class EventAllocator
extends java.lang.Object
| Constructor and Description |
|---|
EventAllocator() |
EventAllocator(java.lang.Class[] classes)
Create a new
EventAllocator, containing pre-created
Allocators for given es. |
| Modifier and Type | Method and Description |
|---|---|
static EventAllocator |
defaultEventAllocator()
Default Event Allocator, uses
ReferenceCountingAllocator for
allocating and recycling events. |
<T> Reference<reactor.bus.Event<T>> |
get(java.lang.Class<T> klass)
Allocate an object from the internal pool, based on the type of Event.
|
protected abstract <T> Allocator<reactor.bus.Event<T>> |
makeAllocator(java.lang.Class<T> klass)
Make a new allocator for
Events with generic type of |
public EventAllocator()
public EventAllocator(java.lang.Class[] classes)
EventAllocator, containing pre-created
Allocators for given es.classes - public <T> Reference<reactor.bus.Event<T>> get(java.lang.Class<T> klass)
T - generic type of Eventklass - generic type of EventReference that can be retained and released.protected abstract <T> Allocator<reactor.bus.Event<T>> makeAllocator(java.lang.Class<T> klass)
Events with generic type of T - generic type of Eventklass - generic type of Eventpublic static EventAllocator defaultEventAllocator()
ReferenceCountingAllocator for
allocating and recycling events.