httk.core.datastream.textstream_url¶
Classes¶
Backend for streaming text fetched from a URL string. |
Module Contents¶
- class httk.core.datastream.textstream_url.TextstreamURL(url, **hints)¶
Bases:
httk.core.datastream.textstream_common.TextstreamCommon,httk.core.datastream.textstream_backend.TextstreamBackendBackend for streaming text fetched from a URL string. A bare string is interpreted as a URL when its scheme is one of http, https, ftp, or file, or when an explicit kind=”url” hint is given. Network access from an implicit bare network URL requires explicit consent before opening; URL views and
kind="url"provide that consent. Content is transparently decompressed before text decoding.- Parameters:
url (str) – URL to fetch lazily when text is first read.
**hints (Any) – Backend-selection, consent, encoding, timeout, and compression hints.
- Raises:
ValueError – If the compression hint is unknown.