Agora Java API Reference for Android
Public Member Functions | Static Public Member Functions | List of all members
agora::rtm::IChannelAttributes Class Referenceabstract

#include <IAgoraRtmService.h>

Public Member Functions

virtual int addAttribute (const char *key, const char *value)=0
 
virtual int removeAttribute (const char *key)=0
 
virtual int getAttributesSize () const =0
 
virtual void getAttributes (int size, char **key, char **value) const =0
 
virtual const char * getAttributeValue (const char *key) const =0
 
virtual int release ()=0
 

Static Public Member Functions

static IChannelAttributescreateChannelAttributes ()
 

Detailed Description

The IChannelAttributes class.

Member Function Documentation

◆ createChannelAttributes()

static IChannelAttributes* agora::rtm::IChannelAttributes::createChannelAttributes ( )
static

Creates an IChannelAttributes instance.

Returns

◆ addAttribute()

virtual int agora::rtm::IChannelAttributes::addAttribute ( const char *  key,
const char *  value 
)
pure virtual

Adds an attribute to a specified channel.

Parameters
keyThe pointer to the attribute key.
valueThe pointer to the attribute value.
Returns
  • 0: Success.
  • < 0: Failure.

◆ removeAttribute()

virtual int agora::rtm::IChannelAttributes::removeAttribute ( const char *  key)
pure virtual

Removes an attribute from the channel.

Parameters
keyThe pointer to the attribute key.
Returns
  • 0: Success.
  • < 0: Failure.

◆ getAttributesSize()

virtual int agora::rtm::IChannelAttributes::getAttributesSize ( ) const
pure virtual

Gets the size of the attributes.

Returns
  • 0: Success.
  • < 0: Failure.

◆ getAttributes()

virtual void agora::rtm::IChannelAttributes::getAttributes ( int  size,
char **  key,
char **  value 
) const
pure virtual

Gets the channel attributes.

Parameters
sizeThe size of the channel attributes.
keyThe pointer to the key of each channel attribute.
valueThe pointer to the value of each channel attribute.

◆ getAttributeValue()

virtual const char* agora::rtm::IChannelAttributes::getAttributeValue ( const char *  key) const
pure virtual

Gets the value of a channel attribute using the attribute key.

Parameters
keyThe pointer to the key of the channel attribute that you want to get.

◆ release()

virtual int agora::rtm::IChannelAttributes::release ( )
pure virtual

Releases the IChannelAttributes instance.

Parameters
-0: Success.
  • < 0: Failure.