Gio.NetworkMonitor.prototype.can_reach_async
function can_reach_async(connectable: Gio.SocketConnectable, cancellable: Gio.Cancellable, callback: Gio.AsyncReadyCallback): void { // Gjs wrapper for g_network_monitor_can_reach_async() }
Asynchronously attempts to determine whether or not the host pointed to by connectable can be reached, without actually trying to connect to it.
For more details, see Gio.NetworkMonitor.prototype.can_reach.
When the operation is finished, callback will be called. You can then call Gio.NetworkMonitor.prototype.can_reach_finish to get the result of the operation.
- connectable
- cancellable
a Gio.Cancellable, or null
- callback
a Gio.AsyncReadyCallback to call when the request is satisfied