Skip to main content

read_source

Function read_source 

Source
pub fn read_source(argument: &str, limits: ReadLimits) -> Result<String, String>
Expand description

Reads the text an argument names. http: and https: are fetched, following redirects, within limits; data: is decoded; file: is turned into a path and read as paths are. Any other scheme is refused.

ยงErrors

The reason the source is unreadable, unsupported, slow or larger than the cap. The message does not repeat the argument; the caller names it.