public static class ResourceSemaphore.Group extends Object
ResourceSemaphores.| 限定符和类型 | 字段和说明 |
|---|---|
static int |
SUCCESS |
| 构造器和说明 |
|---|
Group(int... limits) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
acquire(int... permits) |
void |
close() |
protected ResourceSemaphore |
get(int i) |
boolean |
isClosed() |
protected void |
release(int... permits) |
int |
resourceSize() |
String |
toString() |
int |
tryAcquire(int... permits) |
public static final int SUCCESS
public int resourceSize()
protected ResourceSemaphore get(int i)
public int tryAcquire(int... permits)
SUCCESS if successfully acquired; otherwise, return the failed index.public void acquire(int... permits)
throws InterruptedException
protected void release(int... permits)
public void close()
public boolean isClosed()
Copyright © 2017–2023 The Apache Software Foundation. All rights reserved.