gloox 1.0
|
00001 /* 00002 Copyright (c) 2005-2009 by Jakob Schroeter <js@camaya.net> 00003 This file is part of the gloox library. http://camaya.net/gloox 00004 00005 This software is distributed under a license. The full license 00006 agreement can be found in the file LICENSE in this distribution. 00007 This software may not be copied, modified, sold or distributed 00008 other than expressed in the named license agreement. 00009 00010 This software is distributed without any warranty. 00011 */ 00012 00013 00014 #ifndef PRIVACYLISTHANDLER_H__ 00015 #define PRIVACYLISTHANDLER_H__ 00016 00017 #include "privacyitem.h" 00018 #include "gloox.h" 00019 00020 #include <string> 00021 #include <list> 00022 00023 namespace gloox 00024 { 00025 00029 enum PrivacyListResult 00030 { 00031 ResultStoreSuccess, 00032 ResultActivateSuccess, 00033 ResultDefaultSuccess, 00034 ResultRemoveSuccess, 00035 ResultRequestNamesSuccess, 00036 ResultRequestListSuccess, 00037 ResultConflict, 00039 ResultItemNotFound, 00040 ResultBadRequest, 00041 ResultUnknownError 00042 }; 00043 00050 class GLOOX_API PrivacyListHandler 00051 { 00052 public: 00053 00057 typedef std::list<PrivacyItem> PrivacyList; 00058 00062 virtual ~PrivacyListHandler() {} 00063 00071 virtual void handlePrivacyListNames( const std::string& active, const std::string& def, 00072 const StringList& lists ) = 0; 00073 00080 virtual void handlePrivacyList( const std::string& name, const PrivacyList& items ) = 0; 00081 00086 virtual void handlePrivacyListChanged( const std::string& name ) = 0; 00087 00093 virtual void handlePrivacyListResult( const std::string& id, PrivacyListResult plResult ) = 0; 00094 00095 }; 00096 00097 } 00098 00099 #endif // PRIVACYLISTHANDLER_H__