MulticastLock class

Allows an application to receive Wifi Multicast packets. Normally the Wifi stack filters out packets not explicitly addressed to this device. Acquring a MulticastLock will cause the stack to receive packets addressed to multicast addresses. Processing these extra packets can cause a noticeable battery drain and should be disabled when not needed.

Constructors

MulticastLock()
factory
MulticastLock.private()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

acquire() Future<void>
Locks Wifi Multicast on until release() is called.
isHeld() Future<bool?>
Checks whether this MulticastLock is currently held.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
release() Future<void>
Unlocks Wifi Multicast, restoring the filter of packets not addressed specifically to this device and saving power.
toString() String
A string representation of this object.
inherited

Operators

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