connectiondatahandler.h
/*
Copyright (c) 2007-2023 by Jakob Schröter <js@camaya.net>
This file is part of the gloox library. http://camaya.net/gloox
This software is distributed under a license. The full license
agreement can be found in the file LICENSE in this distribution.
This software may not be copied, modified, sold or distributed
other than expressed in the named license agreement.
This software is distributed without any warranty.
*/
#ifndef CONNECTIONDATAHANDLER_H__
#define CONNECTIONDATAHANDLER_H__
#include "gloox.h"
#include <string>
namespace gloox
{
class ConnectionBase;
class GLOOX_API ConnectionDataHandler
{
public:
virtual ~ConnectionDataHandler() {}
virtual void handleReceivedData( const ConnectionBase* connection, const std::string& data ) = 0;
virtual void handleConnect( const ConnectionBase* connection ) = 0;
virtual void handleDisconnect( const ConnectionBase* connection, ConnectionError reason ) = 0;
};
}
#endif // CONNECTIONDATAHANDLER_H__
gloox::ConnectionBase
An abstract base class for a connection.
Definition connectionbase.h:35
gloox::ConnectionDataHandler
This is an abstract base class to receive events from a ConnectionBase-derived object.
Definition connectiondatahandler.h:36
gloox::ConnectionDataHandler::handleReceivedData
virtual void handleReceivedData(const ConnectionBase *connection, const std::string &data)=0
gloox::ConnectionDataHandler::~ConnectionDataHandler
virtual ~ConnectionDataHandler()
Definition connectiondatahandler.h:41
gloox::ConnectionDataHandler::handleDisconnect
virtual void handleDisconnect(const ConnectionBase *connection, ConnectionError reason)=0
gloox::ConnectionDataHandler::handleConnect
virtual void handleConnect(const ConnectionBase *connection)=0
gloox
The namespace for the gloox library.
Definition adhoc.cpp:28
gloox::ConnectionError
ConnectionError
Definition gloox.h:684