Package com.twilio.video
Enum NetworkQualityLevel
- java.lang.Object
-
- java.lang.Enum<NetworkQualityLevel>
-
- com.twilio.video.NetworkQualityLevel
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<NetworkQualityLevel>
public enum NetworkQualityLevel extends java.lang.Enum<NetworkQualityLevel>
Twilio's Video SDKs, where possible, attempt to calculate a singular Network Quality Level describing the quality of a Participant's connection to a Room. This value ranges from unknown to 5, with unknown representing that the Network Quality Level can not be determined, 0 representing a failed network connection, 1 representing a poor network connection, and 5 representing an excellent network connection. The SDK calculates this metric only when connected to Group Rooms. In case of a connection to Peer-to-Peer Room the value is expected to be unknown at all times.Note that the Network Quality Level is not an absolute metric but a score relative to the demand being placed on the network. For example, the NQ score might be a 5 while on a good network and publishing only an AudioTrack. Later, if a HD VideoTrack is added, the score might come down to 2. This also means that when the network is not being used at all (i.e. the Client is neither publishing nor subscribing to any tracks) the Network Quality Level will always be 5 given that any network will be capable of complying with a zero communications demand.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description NETWORK_QUALITY_LEVEL_FIVE
The Network Quality is Excellent.NETWORK_QUALITY_LEVEL_FOUR
The Network Quality is Very Good.NETWORK_QUALITY_LEVEL_ONE
The Network Quality is Very Bad.NETWORK_QUALITY_LEVEL_THREE
The Network Quality is Good.NETWORK_QUALITY_LEVEL_TWO
The Network Quality is Bad.NETWORK_QUALITY_LEVEL_UNKNOWN
The Network Quality Level cannot be determined or the Network Quality API has not been enabled.NETWORK_QUALITY_LEVEL_ZERO
The network connection has failed
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static NetworkQualityLevel
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static NetworkQualityLevel[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NETWORK_QUALITY_LEVEL_UNKNOWN
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_UNKNOWN
The Network Quality Level cannot be determined or the Network Quality API has not been enabled.
-
NETWORK_QUALITY_LEVEL_ZERO
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_ZERO
The network connection has failed
-
NETWORK_QUALITY_LEVEL_ONE
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_ONE
The Network Quality is Very Bad.
-
NETWORK_QUALITY_LEVEL_TWO
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_TWO
The Network Quality is Bad.
-
NETWORK_QUALITY_LEVEL_THREE
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_THREE
The Network Quality is Good.
-
NETWORK_QUALITY_LEVEL_FOUR
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_FOUR
The Network Quality is Very Good.
-
NETWORK_QUALITY_LEVEL_FIVE
public static final NetworkQualityLevel NETWORK_QUALITY_LEVEL_FIVE
The Network Quality is Excellent.
-
-
Method Detail
-
values
public static NetworkQualityLevel[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (NetworkQualityLevel c : NetworkQualityLevel.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static NetworkQualityLevel valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-