I'm trying to understand the contract of drainPermits in the Java Semaphore class
The JavaDoc simply reads:
public int drainPermits()
Acquire and return all permits that are immediately available. Returns: the number of permits
If no permits are currently available, does it block and wait until one is available?