Skip to main content

Module network_watch

Module network_watch 

Source
Expand description

The device’s network, as the platform describes it (§6.7, api.md E5).

Each open store watches it from opening to closing. The platform says which usable network the device is on, if any, and whether it is metered; the watch keeps that, and counts each time a usable network appears or the device moves to another one. Each such count is a network report, which ends the waits that followed an attempt with no answer from storage. Losing the network, or a network turning metered or unmetered, counts nothing. Where the platform can’t tell, the watch says so: no network counts and none is metered. A platform that fails to answer after the watch started can’t tell either, but its network may be metered, so the watch calls it metered until the platform answers.

Structs§

NetworkState
What coven knows of the device’s network.
NetworkView
Hears what the store’s watch knows of the network (§6.7).
NetworkWatch
One open store’s watch of the device’s network (§6.7): it starts as the store opens, already holding what the platform says, and stops as it closes. Each owner that acts on the network holds a view of it.
TestNetwork
A network a test drives in place of the platform’s (api.md E1 network): clones drive the same network.

Enums§

NetworkSource
Where the store’s watch hears about the network: the platform’s own, or a test’s.
NetworkWatchError
The platform refused to let coven watch the device’s network (api.md E1, E5), such as an Android app without coven’s Android library.