Agora RTC Objective-C API Reference Refactor

Public Member Functions
IDataChannelObserver Class Reference

## Public Member Functions
virtual void | onLocalDataChannelPublished (agora_refptr< ILocalDataChannel > channel)
virtual void | onRemoteDataChannelSubscribed (agora_refptr< IRemoteDataChannel > channel)
virtual void | onRemoteDataChannelUnsubscribed (agora_refptr< IRemoteDataChannel > channel)
virtual void | onRemoteDataPacketReceived (const UserDataChannelInfo &info, util::AString packet)
virtual void | onRemoteDataChannelInfoUpdated (const UserDataChannelInfo *modified_infos, size_t modified_infos_size, const UserDataChannelInfo *deleted_infos, size_t deleted_infos_size)

## Constructor & Destructor Documentation

## ◆ ~IDataChannelObserver()

virtual ~IDataChannelObserver | ( |  | ) |
| inlinevirtual

## Member Function Documentation

## ◆ onLocalDataChannelPublished()

virtual void onLocalDataChannelPublished | ( | agora_refptr< ILocalDataChannel > | channel | ) |
| inlinevirtual

Occurs when the channe is ready to send the data packet.

Parameters

  channel | the published channel.

## ◆ onRemoteDataChannelSubscribed()

virtual void onRemoteDataChannelSubscribed | ( | agora_refptr< IRemoteDataChannel > | channel | ) |
| inlinevirtual

Occurs when the the channe is added and ready to receive data packet.

Parameters

  channel | the remote channel pointer.

## ◆ onRemoteDataChannelUnsubscribed()

virtual void onRemoteDataChannelUnsubscribed | ( | agora_refptr< IRemoteDataChannel > | channel | ) |
| inlinevirtual

Occurs when the the channe is removed.

Parameters

  channel | the remote channel pointer.

## ◆ onRemoteDataPacketReceived()

virtual void onRemoteDataPacketReceived | ( | const UserDataChannelInfo & | info,
|  | util::AString | packet
| ) |  |
| inlinevirtual

Occurs when the packet is received.

Parameters

  info | the channel Info.
  packet | the received packet.

## ◆ onRemoteDataChannelInfoUpdated()

virtual void onRemoteDataChannelInfoUpdated | ( | const UserDataChannelInfo * | modified_infos,
|  | size_t | modified_infos_size,
|  | const UserDataChannelInfo * | deleted_infos,
|  | size_t | deleted_infos_size
| ) |  |
| inlinevirtual

Occurs when the remote data channel info updated.

Parameters

  modified_infos | the modifed channel Infos, add or update.
  modified_infos_size | the size of modifed channel Infos .
  deleted_infos | the deleted channel Infos.
  deleted_infos_size | the size of deleted channel Infos .