Class WorkQueue.WorkUnitWrapper<T>

  • Type Parameters:
    T - the generic type
    Enclosing class:
    WorkQueue<T>

    private static class WorkQueue.WorkUnitWrapper<T>
    extends java.lang.Object
    A wrapper for work units (needed to send a poison pill as a null value, since BlockingQueue does not accept null values).
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) T workUnit
      The work unit.
    • Constructor Summary

      Constructors 
      Constructor Description
      WorkUnitWrapper​(T workUnit)
      Constructor.
    • Method Summary

      • Methods inherited from class java.lang.Object

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

      • workUnit

        final T workUnit
        The work unit.
    • Constructor Detail

      • WorkUnitWrapper

        public WorkUnitWrapper​(T workUnit)
        Constructor.
        Parameters:
        workUnit - the work unit, or null to represent a poison pill.