NetworkConditions class

Constructors

NetworkConditions({required String urlPattern, required num latency, required num downloadThroughput, required num uploadThroughput, ConnectionType? connectionType, num? packetLoss, int? packetQueueLength, bool? packetReordering})
NetworkConditions.fromJson(Map<String, dynamic> json)
factory

Properties

connectionType ConnectionType?
Connection type if known.
final
downloadThroughput num
Maximal aggregated download throughput (bytes/sec). -1 disables download throttling.
final
hashCode int
The hash code for this object.
no setterinherited
latency num
Minimum latency from request sent to response headers received (ms).
final
packetLoss num?
WebRTC packet loss (percent, 0-100). 0 disables packet loss emulation, 100 drops all the packets.
final
packetQueueLength int?
WebRTC packet queue length (packet). 0 removes any queue length limitations.
final
packetReordering bool?
WebRTC packetReordering feature.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
uploadThroughput num
Maximal aggregated upload throughput (bytes/sec). -1 disables upload throttling.
final
urlPattern String
Only matching requests will be affected by these conditions. Patterns use the URLPattern constructor string syntax (https://urlpattern.spec.whatwg.org/) and must be absolute. If the pattern is empty, all requests are matched (including p2p connections).
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
toString() String
A string representation of this object.
inherited

Operators

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