component.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef COMPONENT_H__
00016 #define COMPONENT_H__
00017
00018 #include "clientbase.h"
00019
00020 #include <string>
00021
00022 namespace gloox
00023 {
00024
00033 class GLOOX_API Component : public ClientBase
00034 {
00035 public:
00046 Component( const std::string& ns, const std::string& server,
00047 const std::string& component, const std::string& password, int port = 5347 );
00048
00052 virtual ~Component() {}
00053
00057 void disconnect() { ClientBase::disconnect( ConnUserDisconnected ); }
00058
00059 protected:
00060 virtual void handleStartNode();
00061 virtual bool handleNormalNode( Stanza *stanza );
00062 virtual bool checkStreamVersion( const std::string& ) { return true; }
00063
00064 private:
00065
00066 virtual void rosterFilled() {}
00067
00068 };
00069
00070 }
00071
00072 #endif // COMPONENT_H__