ConnectionChangedReason enum Null safety

Reasons for the connection state change.

Constants

BannedByServer → const ConnectionChangedReason

The connection between the SDK and Agora’s edge server is banned by Agora’s edge server.

@JsonValue(3)
const ConnectionChangedReason(3)
ClientIpAddressChanged → const ConnectionChangedReason

The client IP address has changed, probably due to a change of the network type, IP address, or network port.

@JsonValue(13)
const ConnectionChangedReason(13)
Connecting → const ConnectionChangedReason

The SDK is connecting to Agora’s edge server.

@JsonValue(0)
const ConnectionChangedReason(0)
Interrupted → const ConnectionChangedReason

The connection between the SDK and Agora’s edge server is interrupted.

@JsonValue(2)
const ConnectionChangedReason(2)
InvalidAppId → const ConnectionChangedReason

The specified App ID or Token is invalid. Try to rejoin the channel with a valid App ID or Token.

@JsonValue(6)
const ConnectionChangedReason(6)
InvalidChannelName → const ConnectionChangedReason

The specified channel name is invalid. Try to rejoin the channel with a valid channel name.

@JsonValue(7)
const ConnectionChangedReason(7)
InvalidToken → const ConnectionChangedReason

The generated token is invalid probably due to the following reasons:

  • The App Certificate for the project is enabled in Console, but you do not use Token when joining the channel. If you enable the App Certificate, you must use a token to join the channel.
  • The uid that you specify in the RtcEngine.joinChannel method is different from the uid that you pass for generating the token.
@JsonValue(8)
const ConnectionChangedReason(8)
JoinFailed → const ConnectionChangedReason

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

@JsonValue(4)
const ConnectionChangedReason(4)
JoinSuccess → const ConnectionChangedReason

The SDK has joined the channel successfully.

@JsonValue(1)
const ConnectionChangedReason(1)
KeepAliveTimeout → const ConnectionChangedReason

Timeout for the keep-alive of the connection between the SDK and Agora’s edge server. The connection state changes to:

@JsonValue(14)
const ConnectionChangedReason(14)
LeaveChannel → const ConnectionChangedReason

The SDK has left the channel.

@JsonValue(5)
const ConnectionChangedReason(5)
ProxyServerInterrupted → const ConnectionChangedReason

In cloud proxy mode, the proxy server connection interrupted.

@JsonValue(15)
const ConnectionChangedReason(15)
RejectedByServer → const ConnectionChangedReason

The user is banned by the server.

@JsonValue(10)
const ConnectionChangedReason(10)
RenewToken → const ConnectionChangedReason

The token renews.

@JsonValue(12)
const ConnectionChangedReason(12)
SettingProxyServer → const ConnectionChangedReason

The SDK tries to reconnect after setting a proxy server.

@JsonValue(11)
const ConnectionChangedReason(11)
TokenExpired → const ConnectionChangedReason

The token has expired. Generate a new token from your server.

@JsonValue(9)
const ConnectionChangedReason(9)
values → const List<ConnectionChangedReason>

A constant List of the values in this enum, in order of their declaration.

const List<ConnectionChangedReason>

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
index int

The integer index of this enum.

final
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
A string representation of this object. [...]
override

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited