KeepAliveTimer class
Custom timer for managing keep-alive messages with intelligent activity tracking
- Implemented types
Constructors
- KeepAliveTimer.from(Timer timer)
-
factory
- KeepAliveTimer.periodic(Duration duration, void callback(Timer timer))
-
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isActive → bool
-
Returns whether the timer is still active.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- tick → int
-
The number of durations preceding the most recent timer event.
no setteroverride
Methods
-
cancel(
) → void -
Cancels the timer.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resetTick(
) → void - Reset the tick countdown, restarts the keep-alive timer The next keep-alive message will be sent after the full interval
-
stop(
) → void -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited