00001 #ifndef PSFA_ADMIN_HPP 00002 #define PSFA_ADMIN_HPP 00003 // Copyright (C) 2004 Bernhard Assmann <bernie@tuxomania.net> 00004 // 00005 // This program 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 // This program 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 this program; if not, write to the Free Software 00017 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00018 // 00019 00020 #include <string> 00021 00022 #include "psfa/DbWriteDriver.hpp" 00023 00174 namespace psfa 00175 { 00183 class Admin 00184 { 00185 public: 00186 Admin(); 00187 00188 ~Admin(); 00189 00199 void 00200 init(); 00201 00208 void 00209 del( const std::string poolName ); 00210 00217 void 00218 index( const std::string poolName ); 00219 00225 void 00226 check(); 00227 00234 bool 00235 isSuccess() const; 00236 00237 private: 00238 00247 void 00248 setUpEnviroment(); 00249 00254 DbWriteDriver* db_; 00255 00260 bool success_; 00261 }; 00262 00263 } 00264 #endif