Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members  

bell.cpp

Go to the documentation of this file.
00001 // $Id$
00002 
00003 //**********************************************************************
00004 //                                                                     *
00005 //    Description:   'Bell Master' abstract interface for block        *
00006 //                   instrument bell.                                  *
00007 //                                                                     *
00008 //    Author:        Chris White (whitecf@bcs.org.uk)                  *
00009 //                                                                     *
00010 //    Copyright (C) 2003  Monitor Computing Services Ltd.              *
00011 //                                                                     *
00012 //    This program is free software; you can redistribute it and/or    *
00013 //    modify it under the terms of the GNU General Public License      *
00014 //    as published by the Free Software Foundation; either version 2   *
00015 //    of the License, or any later version.                            *
00016 //                                                                     *
00017 //    This program is distributed in the hope that it will be useful,  *
00018 //    but WITHOUT ANY WARRANTY; without even the implied warranty of   *
00019 //    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the    *
00020 //    GNU General Public License for more details.                     *
00021 //                                                                     *
00022 //    You should have received a copy of the GNU General Public        *
00023 //    License (http://www.gnu.org/copyleft/gpl.html) along with this   *
00024 //    program; if not, write to:                                       *
00025 //       The Free Software Foundation Inc.,                            *
00026 //       59 Temple Place - Suite 330,                                  *
00027 //       Boston, MA  02111-1307,                                       *
00028 //       USA.                                                          *
00029 //                                                                     *
00030 //**********************************************************************
00031 //                                                                     *
00032 //    Notes:                                                           *
00033 //                                                                     *
00034 //**********************************************************************
00035 
00036 #include <mytrace.h>
00037 
00038 #include "bell.h"
00039 
00040 
00041 
00042 using namespace Monitor::BellMaster;
00043 namespace Ut = Monitor::Utility;
00044 
00045 
00046 
00047 Bell::Bell() :
00048     Ut::Watchable()
00049 {
00050     _USEMYTRACE_("Bell::Bell()")
00051 }
00052 
00053 
00054 
00055 Bell::~Bell()
00056 {
00057     _USEMYTRACE_("Bell::~Bell()")
00058 }
00059 
00060 
00061 
00062 const Ut::CallbackBase&
00063 Bell::addListener(const Ut::CallbackBase&    newWatch) const
00064 {
00065     _USEMYTRACE_("Bell::addListener(newWatch)")
00066 
00067 
00068     return addWatch(newWatch);
00069 }
00070 
00071 
00072 
00073 void
00074 Bell::removeListener(const void*    listener) const
00075 {
00076     _USEMYTRACE_("Bell::removeListener(listener)")
00077 
00078 
00079     removeWatcher(listener);
00080 }
00081 
00082 
00083 
00084 void
00085 Bell::ring() const
00086 throw (Bell::Busy)
00087 {
00088     _USEMYTRACE_("Bell::ring()")
00089 
00090 
00091     updated();
00092 }
00093 

Generated on Wed Oct 29 20:54:52 2003 for Bellmaster BC Common by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002