Agora RTC Objective-C API Reference Refactor

Public Member Functions
ILocalDataChannel Class Referenceabstract

Inherits RefCountInterface.

## Public Member Functions
virtual int | sendDataPacket (const char *packet, size_t length)=0
virtual int | setMetaData (const char *metaData, size_t length)=0
virtual Optional< int > | configuredChannelId () const =0

## Constructor & Destructor Documentation

## ◆ ~ILocalDataChannel()

virtual ~ILocalDataChannel | ( |  | ) |
| inlineprotectedvirtual

## Member Function Documentation

## ◆ sendDataPacket()

virtual int sendDataPacket | ( | const char * | packet,
|  | size_t | length
| ) |  |
| pure virtual

Send data packet to this data channel after publishing.

Parameters

  [in] | packet | packet buffer pointer.
  [in] | length | packet buffer length.

Returns
  - 0: Success.
  - < 0: Failure.

## ◆ setMetaData()

virtual int setMetaData | ( | const char * | metaData,
|  | size_t | length
| ) |  |
| pure virtual

Send meta data to this data channel before publishing.

Parameters

  [in] | metaData | meta data pointer.
  [in] | length | meta data length.

Returns
  ····
  - 0: Success.
  - < 0: Failure.

## ◆ configuredChannelId()

virtual Optional<int> configuredChannelId | ( |  | ) | const
| pure virtual

return configured channel id

Returns

## ◆ AddRef()

virtual void AddRef | ( |  | ) | const
| pure virtualinherited

## ◆ Release()

virtual RefCountReleaseStatus Release | ( |  | ) | const
| pure virtualinherited

## ◆ HasOneRef()

virtual bool HasOneRef | ( |  | ) | const
| pure virtualinherited