Closed CBielstein closed 2 years ago
Note to @eddywine for review: Since I add a layer of indentation for the try-finally in AprsIsConnection
AND change a few lines, the diff is all weird there. It may be easier to disable whitespace in the diff. That setting is under the gear in the files tab:
Description
This switches from a simple "logged in" Boolean flag to tracking state across the full life of the
AprsIsConnection
object. It also adds an event which can be subscribed to for notifications of when that status changes.This is especially useful for clients who may wish to know when a connection has been achieved, a login complete, or some error has lead to a disconnect and a new connection is required.
Changes
AprsIsConnection.LoggedIn
in favor ofAprsIsConnection.State
ConnectionState
enum for various states an APRS-IS connection can holdValidation
AprsIsConnection.LoggedIn
toAprsIsConnection.State