Agora RTC Objective-C API Reference  Refactor
Data Structures | Enumerations
AgoraRtmClientKit.h File Reference

Go to the source code of this file.

Data Structures

class  AgoraRtmJoinTopicOption
 
class  AgoraRtmTopicOption
 
class  AgoraRtmJoinChannelOption
 
class  AgoraRtmMessageEvent
 
class  AgoraRtmTopicInfo
 
class  AgoraRtmPresenceEvent
 
class  AgoraRtmClientConfig
 
protocol  <AgoraRtmClientDelegate>
 
class  AgoraRtmClientKit
 
class  AgoraRtmStreamChannel
 

Enumerations

enum  AgoraRtmClientErrorCode {
  AgoraRtmClientErrTopicAlreadyExist = 10001, AgoraRtmClientErrExceedCreateTopicLimitation = 10002, AgoraRtmClientErrInvalidTopicName = 10003, AgoraRtmClientErrPublishTopicFailed = 10004,
  AgoraRtmClientErrExceedSubscribeTopicLimitation = 10005, AgoraRtmClientErrExceedUserLimitation = 10006, AgoraRtmClientErrExceedChannelLimitation = 10007, AgoraRtmClientErrAlreadyJoinChannel = 10008,
  AgoraRtmClientErrNotJoinChannel = 10009
}
 
enum  AgoraRtmClientConnectionState {
  AgoraRtmClientConnectionStateDisconnected = 1, AgoraRtmClientConnectionStateConnecting = 2, AgoraRtmClientConnectionStateConnected = 3, AgoraRtmClientConnectionStateReconnecting = 4,
  AgoraRtmClientConnectionStateFailed = 5
}
 
enum  AgoraRtmClientConnectionChangeReason {
  AgoraRtmClientConnectionChangedConnecting = 0, AgoraRtmClientConnectionChangedJoinSuccess = 1, AgoraRtmClientConnectionChangedInterrupted = 2, AgoraRtmClientConnectionChangedBannedByServer = 3,
  AgoraRtmClientConnectionChangedJoinFailed = 4, AgoraRtmClientConnectionChangedLeaveChannel = 5, AgoraRtmClientConnectionChangedInvalidAppId = 6, AgoraRtmClientConnectionChangedInvalidChannelName = 7,
  AgoraRtmClientConnectionChangedInvalidToken = 8, AgoraRtmClientConnectionChangedTokenExpired = 9, AgoraRtmClientConnectionChangedRejectedByServer = 10, AgoraRtmClientConnectionChangedSettingProxyServer = 11,
  AgoraRtmClientConnectionChangedRenewToken = 12, AgoraRtmClientConnectionChangedClientIpAddressChanged = 13, AgoraRtmClientConnectionChangedKeepAliveTimeout = 14, AgoraRtmClientConnectionChangedRejoinSuccess = 15,
  AgoraRtmClientConnectionChangedChangedLost = 16, AgoraRtmClientConnectionChangedEchoTest = 17, AgoraRtmClientConnectionChangedClientIpAddressChangedByUser = 18, AgoraRtmClientConnectionChangedSameUidLogin = 19,
  AgoraRtmClientConnectionChangedTooManyBroadcasters = 20
}
 
enum  AgoraRtmChannelType { AgoraRtmChannelTypeMessage = 0, AgoraRtmChannelTypeStream = 1 }
 
enum  AgoraRtmPresenceType {
  AgoraRtmPresenceTypeRemoteJoinChannel = 0, AgoraRtmPresenceTypeRemoteLeaveChannel = 1, AgoraRtmPresenceTypeRemoteConnectionTimeout = 2, AgoraRtmPresenceTypeRemoteJoinTopic = 3,
  AgoraRtmPresenceTypeRemoteLeaveTopic = 4, AgoraRtmPresenceTypeSelfJoinChannel = 5
}
 
enum  AgoraRtmStreamChannelErrorCode { AgoraRtmStreamChannelErrorOk = 0, AgoraRtmStreamChannelErroExceedLimitation = 1, AgoraRtmStreamChannelErrorUserNotExist = 2 }
 
enum  AgoraRtmMessageQos { AgoraRtmMessageQosUnordered = 0, AgoraRtmMessageQosOrdered = 1 }
 

Enumeration Type Documentation

◆ AgoraRtmClientErrorCode

The error codes of rtm client.

Enumerator
AgoraRtmClientErrTopicAlreadyExist 

10001: The topic already joined

AgoraRtmClientErrExceedCreateTopicLimitation 

10002: Exceed topic limiation when try to join new topic

AgoraRtmClientErrInvalidTopicName 

10003: Topic name is invalid

AgoraRtmClientErrPublishTopicFailed 

10004: Publish topic message failed

AgoraRtmClientErrExceedSubscribeTopicLimitation 

10005: Exceed topic limitation when try to subscribe new topic

AgoraRtmClientErrExceedUserLimitation 

10006: Exceed user limitation when try to subscribe new topic

AgoraRtmClientErrExceedChannelLimitation 

10007: Exceed channel limitation when try to join new channel

AgoraRtmClientErrAlreadyJoinChannel 

10008: The channel already joined

AgoraRtmClientErrNotJoinChannel 

10009: Try to perform channel related operation before joining channel

◆ AgoraRtmClientConnectionState

Connection states between rtm sdk and agora server.

Enumerator
AgoraRtmClientConnectionStateDisconnected 

1: The SDK is disconnected with server.

AgoraRtmClientConnectionStateConnecting 

2: The SDK is connecting to the server.

AgoraRtmClientConnectionStateConnected 

3: The SDK is connected to the server and has joined a channel. You can now publish or subscribe to a track in the channel.

AgoraRtmClientConnectionStateReconnecting 

4: The SDK keeps rejoining the channel after being disconnected from the channel, probably because of network issues.

AgoraRtmClientConnectionStateFailed 

5: The SDK fails to connect to the server or join the channel.

◆ AgoraRtmClientConnectionChangeReason

Reasons for connection state change.

Enumerator
AgoraRtmClientConnectionChangedConnecting 

0: The SDK is connecting to the server.

AgoraRtmClientConnectionChangedJoinSuccess 

1: The SDK has joined the channel successfully.

AgoraRtmClientConnectionChangedInterrupted 

2: The connection between the SDK and the server is interrupted.

AgoraRtmClientConnectionChangedBannedByServer 

3: The connection between the SDK and the server is banned by the server.

AgoraRtmClientConnectionChangedJoinFailed 

4: The SDK fails to join the channel for more than 20 minutes and stops reconnecting to the channel.

AgoraRtmClientConnectionChangedLeaveChannel 

5: The SDK has left the channel.

AgoraRtmClientConnectionChangedInvalidAppId 

6: The connection fails because the App ID is not valid.

AgoraRtmClientConnectionChangedInvalidChannelName 

7: The connection fails because the channel name is not valid.

AgoraRtmClientConnectionChangedInvalidToken 

8: The connection fails because the token is not valid.

AgoraRtmClientConnectionChangedTokenExpired 

9: The connection fails because the token has expired.

AgoraRtmClientConnectionChangedRejectedByServer 

10: The connection is rejected by the server.

AgoraRtmClientConnectionChangedSettingProxyServer 

11: The connection changes to reconnecting because the SDK has set a proxy server.

AgoraRtmClientConnectionChangedRenewToken 

12: When the connection state changes because the app has renewed the token.

AgoraRtmClientConnectionChangedClientIpAddressChanged 

13: The IP Address of the app has changed. A change in the network type or IP/Port changes the IP address of the app.

AgoraRtmClientConnectionChangedKeepAliveTimeout 

14: A timeout occurs for the keep-alive of the connection between the SDK and the server.

AgoraRtmClientConnectionChangedRejoinSuccess 

15: The SDK has rejoined the channel successfully.

AgoraRtmClientConnectionChangedChangedLost 

16: The connection between the SDK and the server is lost.

AgoraRtmClientConnectionChangedEchoTest 

17: The change of connection state is caused by echo test.

AgoraRtmClientConnectionChangedClientIpAddressChangedByUser 

18: The local IP Address is changed by user.

AgoraRtmClientConnectionChangedSameUidLogin 

19: The connection is failed due to join the same channel on another device with the same uid.

AgoraRtmClientConnectionChangedTooManyBroadcasters 

20: The connection is failed due to too many broadcasters in the channel.

◆ AgoraRtmChannelType

rtm channel type.

Enumerator
AgoraRtmChannelTypeMessage 

0: message channel.

AgoraRtmChannelTypeStream 

1: stream channel.

◆ AgoraRtmPresenceType

RTM presence type.

Enumerator
AgoraRtmPresenceTypeRemoteJoinChannel 

0: Triggered when remote user join channel

AgoraRtmPresenceTypeRemoteLeaveChannel 

1: Triggered when remote leave join channel

AgoraRtmPresenceTypeRemoteConnectionTimeout 

2: Triggered when remote user's connection timeout

AgoraRtmPresenceTypeRemoteJoinTopic 

3: Triggered when remote user join a topic

AgoraRtmPresenceTypeRemoteLeaveTopic 

4: Triggered when remote user leave a topic

AgoraRtmPresenceTypeSelfJoinChannel 

5: Triggered when local user join channel

◆ AgoraRtmStreamChannelErrorCode

RTM error code occurs in stream channel.

Enumerator
AgoraRtmStreamChannelErrorOk 

0: No error occurs.

AgoraRtmStreamChannelErroExceedLimitation 

1: Triggered when subscribe user exceed limitation

AgoraRtmStreamChannelErrorUserNotExist 

2: Triggered when unsubscribe inexistent user

◆ AgoraRtmMessageQos

The qos of rtm message.

Enumerator
AgoraRtmMessageQosUnordered 

not ensure messages arrive in order.

AgoraRtmMessageQosOrdered 

ensure messages arrive in order.