00001 #if !defined(__CORELINUXGUARDGROUP_HPP)
00002 #define __CORELINUXGUARDGROUP_HPP
00003
00004 /*
00005 CoreLinux++
00006 Copyright (C) 1999,2000 CoreLinux Consortium
00007
00008 The CoreLinux++ Library is free software; you can redistribute it and/or
00009 modify it under the terms of the GNU Library General Public License as
00010 published by the Free Software Foundation; either version 2 of the
00011 License, or (at your option) any later version.
00012
00013 The CoreLinux++ Library Library is distributed in the hope that it will
00014 be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
00015 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
00016 Library General Public License for more details.
00017
00018 You should have received a copy of the GNU Library General Public
00019 License along with the GNU C Library; see the file COPYING.LIB. If not,
00020 write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00021 Boston, MA 02111-1307, USA.
00022 */
00023
00024 #if !defined(__COMMON_HPP)
00025 #include <Common.hpp>
00026 #endif
00027
00028 #if !defined(__SEMAPHOREGROUP_HPP)
00029 #include <SemaphoreGroup.hpp>
00030 #endif
00031
00032 namespace corelinux
00033 {
00034 DECLARE_CLASS( CoreLinuxGuardGroup );
00035
00041 class CoreLinuxGuardGroup : public SemaphoreGroup
00042 {
00043 public:
00044
00055 CoreLinuxGuardGroup( Short )
00056 throw(Assertion,SemaphoreException);
00057
00059
00060 virtual ~CoreLinuxGuardGroup( void );
00061
00062 //
00063 // Accessors
00064 //
00065
00066 //
00067 // Factory methods
00068 //
00069
00076 virtual AbstractSemaphorePtr createSemaphore( void )
00077 throw( SemaphoreException ) ;
00078
00096 virtual AbstractSemaphorePtr createSemaphore
00097 (
00098 SemaphoreIdentifierRef aIdentifier,
00099 CreateDisposition disp = CREATE_OR_REUSE,
00100 bool Recursive = false,
00101 bool Balking = false
00102 ) throw( SemaphoreException ) ;
00103
00121 virtual AbstractSemaphorePtr createSemaphore
00122 (
00123 std::string aName,
00124 CreateDisposition disp = CREATE_OR_REUSE,
00125 bool Recursive=false,
00126 bool Balking = false
00127 ) throw( SemaphoreException ) ;
00128
00129
00140 virtual void destroySemaphore( AbstractSemaphorePtr )
00141 throw( SemaphoreException ) ;
00142 protected:
00143
00144 //
00145 // Constructors
00146 //
00148
00149 CoreLinuxGuardGroup( void ) throw( Assertion );
00150
00152
00153 CoreLinuxGuardGroup( CoreLinuxGuardGroupCref )
00154 throw( Assertion );
00155
00156 //
00157 // Operator overloads
00158 //
00159
00161
00162 CoreLinuxGuardGroupRef operator=( CoreLinuxGuardGroupCref )
00163 throw( Assertion );
00164
00165 //
00166 // Directed Factory methods
00167 //
00168
00169
00170 private:
00171
00173
00174 AbstractSemaphorePtr *theUsedMap;
00175 };
00176 }
00177
00178 #endif // if !defined(__CORELINUXGUARDGROUP_HPP)
00179
00180 /*
00181 Common rcs information do not modify
00182 $Author: frankc $
00183 $Revision: 1.2 $
00184 $Date: 2000/06/02 11:51:52 $
00185 $Locker: $
00186 */
00187
00188
00189