001/* A live signal plotter applet 002 003 @Author: Edward A. Lee and Christopher Brooks 004 005 @Copyright (c) 1997-2014 The Regents of the University of California. 006 All rights reserved. 007 008 Permission is hereby granted, without written agreement and without 009 license or royalty fees, to use, copy, modify, and distribute this 010 software and its documentation for any purpose, provided that the 011 above copyright notice and the following two paragraphs appear in all 012 copies of this software. 013 014 IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY 015 FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES 016 ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF 017 THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF 018 SUCH DAMAGE. 019 020 THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, 021 INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 022 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE 023 PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE UNIVERSITY OF 024 CALIFORNIA HAS NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, 025 ENHANCEMENTS, OR MODIFICATIONS. 026 027 PT_COPYRIGHT_VERSION_2 028 COPYRIGHTENDKEY 029 */ 030package ptolemy.plot; 031 032////////////////////////////////////////////////////////////////////////// 033//// PlotLiveApplet 034 035/** 036 An Applet for the PlotLive class. Derived classes should redefine 037 newPlot() to return a concrete instance of PlotLive. 038 039 @author Edward A. Lee, Christopher Brooks 040 @version $Id$ 041 @since Ptolemy II 0.2 042 @Pt.ProposedRating Yellow (cxh) 043 @Pt.AcceptedRating Yellow (cxh) 044 */ 045@SuppressWarnings("serial") 046public class PlotLiveApplet extends PlotApplet { 047 /** Return a string describing this applet. 048 * @return A description of the applet. 049 */ 050 @Override 051 public String getAppletInfo() { 052 return "PlotLiveApplet " + PlotBox.PTPLOT_RELEASE 053 + " : Demo of PlotLive.\n" + "By: Edward A. Lee\n" 054 + " Christopher Brooks\n" + "($Id$)"; 055 } 056 057 /** Start the plot thread. 058 */ 059 @Override 060 public void start() { 061 ((PlotLive) plot()).start(); 062 } 063 064 /** Stop the plot thread. 065 */ 066 @Override 067 public void stop() { 068 ((PlotLive) plot()).stop(); 069 } 070}