class_docstr: Stripped-down fork of the standard library Queue that is closeable.
class_docstr_tok: ["Stripped-down","fork","of","the","standard","library","Queue","that","is","closeable","."]
docstr: Put an item into the queue.
  
  If the queue is closed, fails immediately.
  
  If the queue is full, blocks until space is available or until the queue
  is closed by a call to close(), at which point this call fails.
  
  Args:
    item: an item to add to the queue
  
  Raises:
    QueueClosedError: if insertion failed because the queue is closed
docstr_tok: ["Put","an","item","into","the","queue",".","If","the","queue","is","closed",",","fails","immediately",".","If","the","queue","is","full",",","blocks","until","space","is","available","or","until","the","queue","is","closed","by","a","call","to","close","(",")",",","at","which","point","this","call","fails",".","Args",":","item",":","an","item","to","add","to","the","queue","Raises",":","QueueClosedError",":","if","insertion","failed","because","the","queue","is","closed"]
code: def put(self, item):
      """Put an item into the queue.
  
      If the queue is closed, fails immediately.
  
      If the queue is full, blocks until space is available or until the queue
      is closed by a call to close(), at which point this call fails.
  
      Args:
        item: an item to add to the queue
  
      Raises:
        QueueClosedError: if insertion failed because the queue is closed
      """
      with self._not_full:
          if self._closed:
              raise QueueClosedError()
          if self._maxsize > 0:
              while len(self._queue) == self._maxsize:
                  self._not_full.wait()
                  if self._closed:
                      raise QueueClosedError()
          self._queue.append(item)
          self._not_empty.notify()
  
imports: import collections
  import os.path
  import sys
  import threading
  import time
  from tensorflow.python.client import _pywrap_events_writer
  from tensorflow.python.platform import gfile
  from tensorflow.python.platform import tf_logging
  from tensorflow.python.util import compat
label_desc: Use image node_id 3 for calling the CloseableQueue obj's underlying member method code with example usage: obj.put(item) without return types