Class ReentrantSliceLock

    • Constructor Detail

      • ReentrantSliceLock

        public ReentrantSliceLock()
      • ReentrantSliceLock

        public ReentrantSliceLock​(boolean fair)
    • Method Detail

      • lock

        public void lock()
        Locks only for parent thread and let the child use parent's lock.
        Specified by:
        lock in interface Lock
        Overrides:
        lock in class ReentrantLock
      • unlock

        public void unlock()
        Unlocks only if parent thread.
        Specified by:
        unlock in interface Lock
        Overrides:
        unlock in class ReentrantLock