00001 /* 00002 Copyright 2007 Erez Bibi (erezbibi@users.sourceforge.net) 00003 This file is part of Beesnest. 00004 00005 Beesnest is free software; you can redistribute it and/or modify 00006 it under the terms of the GNU General Public License as published by 00007 the Free Software Foundation; either version 2 of the License, or 00008 (at your option) any later version. 00009 00010 Beesnest is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 GNU General Public License for more details. 00014 00015 You should have received a copy of the GNU General Public License 00016 along with Beesnest; if not, write to the Free Software 00017 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00018 */ 00019 00020 #ifndef __CDC_USER_STATUS 00021 #define __CDC_USER_STATUS 00022 00023 00024 #include "DcGlobals.h" 00025 #include "DcAdaptersSet.h" 00026 #include "DcEnginesSet.h" 00027 00028 /** 00029 * This simple class holds an Adapters Set and an Engines Set in the same object. 00030 * This is the logged in user "status" Beesnest keeps between requests. 00031 */ 00032 00033 00034 class CdcUserStatus 00035 { 00036 public: 00037 CdcAdaptersSet* GetAdaptersSet () { return &oAdaptersSet; } 00038 00039 CdcEnginesSet* GetEnginesSet () { return &oEnginesSet; } 00040 00041 void Login () { oAdaptersSet.Login (); oEnginesSet.Login (); } 00042 00043 void Logout () { oAdaptersSet.Logout (); oEnginesSet.Logout (); } 00044 00045 private: 00046 /** The Adapters Set object of this user. */ 00047 CdcAdaptersSet oAdaptersSet; 00048 00049 /** The Engines Set object of this user. */ 00050 CdcEnginesSet oEnginesSet; 00051 }; 00052 00053 #endif /* __CDC_USER_STATUS */ 00054