public final class CLEventList extends Object implements CLResource, AutoCloseable, Iterable<CLEvent>
Constructor and Description |
---|
CLEventList(CachedBufferFactory factory,
CLEvent... events) |
CLEventList(CachedBufferFactory factory,
int capacity) |
CLEventList(CLEvent... events) |
CLEventList(int capacity) |
Modifier and Type | Method and Description |
---|---|
int |
capacity()
Returns the maximum size of this list.
|
void |
close()
Deprecated.
use
release() instead. |
CLEvent |
getEvent(int index) |
boolean |
isReleased()
Returns true if
CLResource.release() has been called. |
Iterator<CLEvent> |
iterator() |
void |
release()
Releases all CLEvents in this list.
|
int |
size()
Returns the current size of this list.
|
String |
toString() |
void |
waitForEvent(int index)
Waits for the event with the given index in this list to occur.
|
void |
waitForEvents()
Waits for all events in this list to occur.
|
void |
waitForEvents(int start,
int range)
Waits for all events of the specified region in this list to occur.
|
public CLEventList(int capacity)
public CLEventList(CLEvent... events)
public CLEventList(CachedBufferFactory factory, int capacity)
public CLEventList(CachedBufferFactory factory, CLEvent... events)
public void waitForEvents()
public void waitForEvents(int start, int range)
public void waitForEvent(int index)
public void release()
release
in interface CLResource
@Deprecated public final void close()
release()
instead.close
in interface AutoCloseable
public CLEvent getEvent(int index)
public int size()
public int capacity()
public boolean isReleased()
CLResource
CLResource.release()
has been called.isReleased
in interface CLResource