Class ProducerConsumerLock

java.lang.Object
it.polimi.ingsw.Utility.ProducerConsumerLock
All Implemented Interfaces:
ReadWriteLock

public class ProducerConsumerLock extends Object implements ReadWriteLock
Implements Producer Consumer paradigm
  • Field Details

  • Constructor Details

    • ProducerConsumerLock

      public ProducerConsumerLock(boolean readInitiallyLocked, boolean writeInitiallyLocked)
      Implements Producer Consumer paradigm using a couple of ClassicLocks
      Parameters:
      readInitiallyLocked - read lock initially locked
      writeInitiallyLocked - write lock initially locked
  • Method Details