Class ThreadPool.ConditionVariable

  • Enclosing class:
    ThreadPool

    class ThreadPool.ConditionVariable
    extends java.lang.Object
    A wrapper around an int that acts as a Condition Variable, and is used as such. In behaviour it is probably closer to a semaphore.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int value
      The int that is associated with this object.
    • Constructor Summary

      Constructors 
      Constructor Description
      ConditionVariable()
      The default constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getValue()
      Returns the value.
      void increment()
      It increments the value by 1.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • value

        private int value
        The int that is associated with this object.
    • Constructor Detail

      • ConditionVariable

        public ConditionVariable()
        The default constructor.
    • Method Detail

      • increment

        public void increment()
        It increments the value by 1.
      • getValue

        public int getValue()
        Returns the value.