Class NullSemaphore

  • All Implemented Interfaces:
    Semaphore

    public class NullSemaphore
    extends Object
    implements Semaphore
    Implements a simple semaphore that does not do any semaphore-ing. That is, the methods just immediately return.
    Author:
    Dave Bristor
    • Constructor Detail

      • NullSemaphore

        public NullSemaphore​(String owner)
    • Method Detail

      • acquire

        public void acquire()
        Does nothing.
        Specified by:
        acquire in interface Semaphore
      • release

        public void release()
        Does nothing.
        Specified by:
        release in interface Semaphore