Device: Host 🧪
Channel representing an HTTPS connection to a server.
Type: FetchError
An error may be indicated once either Fetch
or Host
command becomes ready.
To indicate an error, capacity
will be set to 0. buffer.size
will be set to
an error code:
Variants (int
)
Network
- Server unreachable (network error).Hangup
- Server hung up.
Readiness
Becomes ready once either
- The resource host can't be reached (network error),
capacity
set to 0. - The resource host hung up,
capacity
set to 0. - The resource host has sent back a chunk of the resource (a new device
channel has been opened)
- Buffer is not big enough,
buffer
overwritten up tocapacity
bytes, andcapacity
modified how many more bytes are required - Buffer is big enough,
buffer
overwritten,capacity
unchanged.
- Buffer is not big enough,
Command: Host
Variants (int
)
Poll
- Poll for more data from server.Hangup
- Hang up connection to server.
Traps
- If variant is unknown (not
0
or1
)