rosterlistener.h

00001 /*
00002   Copyright (c) 2004-2005 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 ROSTERLISTENER_H__
00015 #define ROSTERLISTENER_H__
00016 
00017 #include "rosteritem.h"
00018 
00019 #include <string>
00020 #include <map>
00021 
00022 namespace gloox
00023 {
00024 
00033   class GLOOX_EXPORT RosterListener
00034   {
00035     public:
00040       typedef std::map<const std::string, RosterItem*> Roster;
00041 
00045       virtual ~RosterListener() {};
00046 
00055       virtual void itemAdded( const std::string& jid ) = 0;
00056 
00062       virtual void itemSubscribed( const std::string& jid ) = 0;
00063 
00071       virtual void itemRemoved( const std::string& jid ) = 0;
00072 
00083       virtual void itemUpdated( const std::string& jid ) = 0;
00084 
00090       virtual void itemUnsubscribed( const std::string& jid ) = 0;
00091 
00100       virtual void roster( Roster& roster ) = 0;
00101 
00111       virtual void itemChanged( RosterItem& item, int status, const std::string& msg ) = 0;
00112 
00120       virtual void itemAvailable( RosterItem& item, const std::string& msg ) = 0;
00121 
00127       virtual void itemUnavailable( RosterItem& item, const std::string& msg ) = 0;
00128 
00139       virtual bool subscriptionRequest( const std::string& jid, const std::string& msg ) = 0;
00140 
00151       virtual bool unsubscriptionRequest( const std::string& jid, const std::string& msg ) = 0;
00152 
00153   };
00154 
00155 }
00156 
00157 #endif // ROSTERLISTENER_H__

Generated on Mon Jan 16 16:19:54 2006 for gloox by  doxygen 1.4.6