Instance Property

betterPathUpdateHandler

A handler that receives updates when an alternative network path is preferred over the current path.

Declaration

final var betterPathUpdateHandler: ((Bool) -> Void)? { get set }

Discussion

Better path events are an indication that a more preferable network path is available. If you can migrate your work to a new connection, try establishing a new connection. Once that new connection is ready, cancel the original connection.

See Also

Handling Path Updates

var currentPath: NWPath?

The network path the connection is using.

var pathUpdateHandler: ((NWPath) -> Void)?

A handler that receives network path updates.

var viabilityUpdateHandler: ((Bool) -> Void)?

A handler that receives updates when data can be sent and received.