Class Semaphore.Standard

  • All Implemented Interfaces:
    java.io.Serializable, Semaphore
    Enclosing interface:
    Semaphore

    public static class Semaphore.Standard
    extends java.util.concurrent.Semaphore
    implements Semaphore
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      Standard​(int permits)  
      Standard​(int permits, boolean fair)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void acquireThrowUncheckedOnInterrupt​(int acquire)
      Take permits, waiting indefinitely until available
      int drain()
      int permits()
      Number of permits that are available to be acquired.
      boolean tryAcquireUntil​(int acquire, long nanoTimeDeadline)
      int waiting()
      Number of permits that have been acquired in excess of available.
      • Methods inherited from class java.util.concurrent.Semaphore

        acquire, acquire, acquireUninterruptibly, acquireUninterruptibly, availablePermits, drainPermits, getQueuedThreads, getQueueLength, hasQueuedThreads, isFair, reducePermits, release, release, toString, tryAcquire, tryAcquire, tryAcquire, tryAcquire
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait