Home · All Classes · All Namespaces · Modules · Functions · Files |
The StreamTubeServer::ParametersGenerator abstract interface allows sending a different set of parameters with each tube offer. More...
#include <TelepathyQt4/StreamTubeServer>
Inherited by Tp::FixedParametersGenerator.
The StreamTubeServer::ParametersGenerator abstract interface allows sending a different set of parameters with each tube offer.
Tube parameters are arbitrary data sent with the tube offer, which can be retrieved in the receiving end with IncomingStreamTubeChannel::parameters(). They can be used to transfer e.g. session identification information, authentication credentials or alike, for bootstrapping the protocol used for communicating over the tube.
For usecases where the parameters don't need to change between each tube, just passing a fixed set of parameters to a suitable StreamTubeServer::exportTcpSocket() overload is usually more convenient than implementing a ParametersGenerator. Note that StreamTubeServer::exportTcpSocket() can be called multiple times to change the parameters for future tubes when e.g. configuration settings have been changed, so a ParametersGenerator only needs to be implemented if each and every tube must have a different set of parameters.
Tp::StreamTubeServer::ParametersGenerator::~ParametersGenerator | ( | ) | [inline, protected, virtual] |
Class destructor. Protected, because StreamTubeServer never deletes a ParametersGenerator passed to it.
QVariantMap Tp::StreamTubeServer::ParametersGenerator::nextParameters | ( | const AccountPtr & | account, |
const OutgoingStreamTubeChannelPtr & | tube, | ||
const ChannelRequestHints & | hints | ||
) | [pure virtual] |
Return the parameters to send when offering the given tube.
account | The account from which the tube originates. |
tube | The tube channel which is going to be offered by the StreamTubeServer. |
hints | The hints associated with the request that led to the creation of this tube, if any. |
Copyright © 2008-2011 Collabora Ltd. and Nokia Corporation | Telepathy-Qt4 0.8.0 |