public static class ResourceSemaphore.Group extends Object
| Constructor and Description |
|---|
Group(int... limits) |
| Modifier and Type | Method and Description |
|---|---|
void |
acquire(int... permits) |
void |
close() |
protected ResourceSemaphore |
get(int i) |
boolean |
isClosed() |
protected void |
release(int... permits) |
int |
resourceSize() |
String |
toString() |
ResourceSemaphore.ResourceAcquireStatus |
tryAcquire(int... permits) |
public int resourceSize()
protected ResourceSemaphore get(int i)
public ResourceSemaphore.ResourceAcquireStatus tryAcquire(int... permits)
public void acquire(int... permits)
throws InterruptedException
InterruptedExceptionprotected void release(int... permits)
public void close()
public boolean isClosed()
Copyright © 2017–2022 The Apache Software Foundation. All rights reserved.