Agora RTC Objective-C API Reference Refactor

IAgoraMediaRelayService.h
Go to the documentation of this file.
1 //
2 // Agora Media SDK
3 //
4 // Created by Xiaosen Wang in 2020.
5 // Copyright (c) 2020 Agora IO. All rights reserved.
6 //
7 #pragma once
8 #include "AgoraBase.h"
9 #include "AgoraRefPtr.h"
10 #include "IAgoraService.h"
11
12 namespace agora {
13 namespace rtc {
14 class IMediaRelayObserver;
15 class IMediaRelayService : public RefCountInterface {
16 public:
30 virtual int startOrUpdateChannelMediaRelay(const ChannelMediaRelayConfiguration& configuration) = 0;
31
44 virtual int stopChannelMediaRelay() = 0;
45
54 virtual int pauseAllChannelMediaRelay() = 0;
55
64 virtual int resumeAllChannelMediaRelay() = 0;
65
66 virtual void registerEventHandler(IMediaRelayObserver* eventObserver, void(*safeDeleter)(IMediaRelayObserver*) = NULL) = 0;
67 virtual void unregisterEventHandler(IMediaRelayObserver* eventObserver) = 0;
68 };
69
70 class IMediaRelayObserver {
71 public:
72 virtual ~IMediaRelayObserver() {}
73
82 virtual void onChannelMediaRelayStateChanged(CHANNEL_MEDIA_RELAY_STATE state,
83 CHANNEL_MEDIA_RELAY_ERROR code) {}
88 virtual void onChannelMediaRelayEvent(CHANNEL_MEDIA_RELAY_EVENT code) {}
89 };
90
91 } // namespace rtc
92 } // namespace agora
agora::rtc::IMediaRelayService
Definition: IAgoraMediaRelayService.h:15
agora::rtc::IMediaRelayObserver
Definition: IAgoraMediaRelayService.h:70
AgoraBase.h
agora::rtc::CHANNEL_MEDIA_RELAY_ERROR
CHANNEL_MEDIA_RELAY_ERROR
Definition: AgoraBase.h:5240
agora::rtc::IMediaRelayService::resumeAllChannelMediaRelay
virtual int resumeAllChannelMediaRelay()=0
agora::rtc::IMediaRelayObserver::onChannelMediaRelayStateChanged
virtual void onChannelMediaRelayStateChanged(CHANNEL_MEDIA_RELAY_STATE state, CHANNEL_MEDIA_RELAY_ERROR code)
Definition: IAgoraMediaRelayService.h:82
agora
Definition: AgoraAtomicOps.h:21
agora::rtc::IMediaRelayService::pauseAllChannelMediaRelay
virtual int pauseAllChannelMediaRelay()=0
agora::rtc::IMediaRelayService::startOrUpdateChannelMediaRelay
virtual int startOrUpdateChannelMediaRelay(const ChannelMediaRelayConfiguration &configuration)=0
agora::rtc::CHANNEL_MEDIA_RELAY_STATE
CHANNEL_MEDIA_RELAY_STATE
Definition: AgoraBase.h:5339
agora::rtc::IMediaRelayService::unregisterEventHandler
virtual void unregisterEventHandler(IMediaRelayObserver *eventObserver)=0
agora::rtc::ChannelMediaRelayConfiguration
Definition: AgoraBase.h:5373
agora::rtc::IMediaRelayService::registerEventHandler
virtual void registerEventHandler(IMediaRelayObserver *eventObserver, void(*safeDeleter)(IMediaRelayObserver *)=NULL)=0
AgoraRefPtr.h
agora::rtc::CHANNEL_MEDIA_RELAY_EVENT
CHANNEL_MEDIA_RELAY_EVENT
Definition: AgoraBase.h:5286
agora::rtc::IMediaRelayObserver::~IMediaRelayObserver
virtual ~IMediaRelayObserver()
Definition: IAgoraMediaRelayService.h:72
agora::RefCountInterface
Definition: AgoraRefPtr.h:31
agora::rtc::IMediaRelayService::stopChannelMediaRelay
virtual int stopChannelMediaRelay()=0
IAgoraService.h
agora::rtc::IMediaRelayObserver::onChannelMediaRelayEvent
virtual void onChannelMediaRelayEvent(CHANNEL_MEDIA_RELAY_EVENT code)
Definition: IAgoraMediaRelayService.h:88