Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

LOW_semaphoreSet.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                           LOW_semaphoreSet.h  -  description
00003                              -------------------
00004     begin                : Mon Jul 29 2002
00005     copyright            : (C) 2002 by Harald Roelle, Helmut Reiser
00006     email                : roelle@informatik.uni-muenchen.de, reiser@informatik.uni-muenchen.de
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #ifndef LOW_SEMAPHORESET_H
00019 #define LOW_SEMAPHORESET_H
00020 
00021 
00022 #include "LOW_exception.h"
00023 
00024 
00025 /** Abstract base class for sets of integer semaphores.
00026     Each instance represents one set of integer semaphores.
00027 
00028     Specific platforms dereive their implementation classes from this class.
00029 
00030     The instances are created by LOW_semaphoreSetFactory, following the factory
00031     design pattern.
00032 
00033     <B>Note:</B> There is no prescribed constructor. A class deriving from this
00034                  class should give the opportunity to specify the number of
00035                  semaphores in the set and their initial value.
00036 
00037     @see LOW_semaphoreSetFactory
00038 
00039     @author Harald Roelle, Helmut Reiser
00040  */
00041 class LOW_semaphoreSet {
00042 
00043 //=======================================================================================
00044 public: 
00045   
00046   //=====================================================================================
00047   //
00048   // exceptions
00049   //
00050  
00051   /** Exception base class for all exceptions thrown by LOW_semaphoreSet. */
00052   class_DERIVE_FROM_EXCEPTION( semSet_error, LOW_exception);
00053   
00054   
00055   //=====================================================================================
00056   //
00057   // methods
00058   //
00059 
00060   /** Decrease a semaphore.
00061       @param  inSemNo  Number of the semaphore in the set.
00062    */  
00063   virtual void decSem( const unsigned int inSemNo) const = 0;
00064   
00065   /** Increase a semaphore.
00066       @param  inSemNo  Number of the semaphore in the set.
00067    */
00068   virtual void incSem( const unsigned int inSemNo) const = 0;
00069 
00070 };
00071 
00072 #endif

Generated on Sun Jan 12 21:07:43 2003 by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001