Class StreamValueListener

  • All Implemented Interfaces:
    ValueListener

    public class StreamValueListener
    extends java.lang.Object
    implements ValueListener
    A value listener that describes value changes on the standard output when the value of an object implementing Settable changes.
    Since:
    Ptolemy II 2.1
    Version:
    $Id$
    Author:
    Christopher Hylands
    See Also:
    Variable
    Pt.AcceptedRating:
    Green (cxh)
    Pt.ProposedRating:
    Green (eal)
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.io.PrintStream _output
      The PrintStream that we direct the output to.
    • Constructor Summary

      Constructors 
      Constructor Description
      StreamValueListener()
      Create a value listener that sends messages to the standard output.
      StreamValueListener​(java.io.OutputStream out)
      Create a value listener that sends messages to the specified stream.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void valueChanged​(Settable settable)
      React to the fact that the specified Settable has changed.
      • Methods inherited from class java.lang.Object

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

      • _output

        protected java.io.PrintStream _output
        The PrintStream that we direct the output to.
    • Constructor Detail

      • StreamValueListener

        public StreamValueListener()
        Create a value listener that sends messages to the standard output.
      • StreamValueListener

        public StreamValueListener​(java.io.OutputStream out)
        Create a value listener that sends messages to the specified stream.
        Parameters:
        out - The stream to send messages to.
    • Method Detail

      • valueChanged

        public void valueChanged​(Settable settable)
        React to the fact that the specified Settable has changed.
        Specified by:
        valueChanged in interface ValueListener
        Parameters:
        settable - The object that has changed value.