3
* Copyright (C) 2006 Remko Troncon
5
* This program is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU General Public License
7
* as published by the Free Software Foundation; either version 2
8
* of the License, or (at your option) any later version.
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public License
16
* along with this library; if not, write to the Free Software
17
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
34
* \brief An abstract class for a voice call implementation.
36
class VoiceCaller : public QObject
42
* \brief Base constructor.
44
* \param account the account to which this voice caller belongs
46
VoiceCaller(PsiAccount* account) : account_(account) { };
49
* \brief Retrieves the account to which this voice caller belongs.
51
PsiAccount* account() { return account_; }
54
* \brief Initializes the voice caller.
55
* This should be called when the connection is open.
57
virtual void initialize() = 0;
60
* \brief De-initializes the voice caller.
61
* This should be called when the connection is about to be closed.
63
virtual void deinitialize() = 0;
66
* \brief Call the given JID.
68
virtual void call(const Jid&) = 0;
71
* \brief Accept a call from the given JID.
73
virtual void accept(const Jid&) = 0;
76
* \brief Reject the call from the given JID.
78
virtual void reject(const Jid&) = 0;
81
* \brief Terminate the call from the given JID.
83
virtual void terminate(const Jid&) = 0;
87
* \brief Incoming call from the given JID.
89
void incoming(const Jid&);
92
* \brief Contact accepted an incoming call.
94
void accepted(const Jid&);
97
* \brief Contact rejected an incoming call.
99
void rejected(const Jid&);
102
* \brief Call with given JID is in progress.
104
void in_progress(const Jid&);
107
* \brief Call with given JID is terminated.
109
void terminated(const Jid&);
112
PsiAccount* account_;