# Listener class

class `pymeasure.experiment.listeners.``Listener`(port, topic='', timeout=0.01)

  Bases: `pymeasure.thread.StoppableThread`

  Base class for Threads that need to listen for messages on a ZMQ TCP port and can be stopped by a thread-safe method call

  `message_waiting`()
  `receive`(flags=0)

class `pymeasure.experiment.listeners.``Monitor`(results, queue)

  Bases: `pymeasure.log.QueueListener`

class `pymeasure.experiment.listeners.``Recorder`(results, queue, **kwargs)

  Bases: `pymeasure.log.QueueListener`

  Recorder loads the initial Results for a filepath and appends data by listening for it over a queue. The queue ensures that no data is lost between the Recorder and Worker.

  `stop`()

    Stop the listener.

    This asks the thread to terminate, and then waits for it to do so. Note that if you don’t call this before your application exits, there may be some records still left on the queue, which won’t be processed.