Line data Source code
1 : /*
2 : * Copyright (C) 2004-2026 Savoir-faire Linux Inc.
3 : *
4 : * This program is free software: you can redistribute it and/or modify
5 : * it under the terms of the GNU General Public License as published by
6 : * the Free Software Foundation, either version 3 of the License, or
7 : * (at your option) any later version.
8 : *
9 : * This program is distributed in the hope that it will be useful,
10 : * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 : * GNU General Public License for more details.
13 : *
14 : * You should have received a copy of the GNU General Public License
15 : * along with this program. If not, see <https://www.gnu.org/licenses/>.
16 : */
17 : #pragma once
18 :
19 : namespace jami {
20 :
21 : /*
22 : * @file remoterecorder.h
23 : * @brief Handles the peer's recording states.
24 : */
25 :
26 : class PeerRecorder
27 : {
28 : public:
29 371 : PeerRecorder() {};
30 371 : virtual ~PeerRecorder() {};
31 :
32 : virtual void peerRecording(bool state) = 0;
33 :
34 199 : virtual bool isPeerRecording() const { return peerRecording_; }
35 :
36 : virtual void peerMuted(bool muted, int streamIdx) = 0;
37 :
38 194 : virtual bool isPeerMuted() const { return peerMuted_; }
39 :
40 : virtual void peerVoice(bool voice) = 0;
41 :
42 0 : virtual bool hasPeerVoice() const { return peerVoice_; }
43 :
44 : protected:
45 : bool peerRecording_ {false};
46 : bool peerMuted_ {false};
47 : bool peerVoice_ {false};
48 : };
49 :
50 : } // namespace jami
|