Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[lib/ocaml] use ocaml Http_client from netclient lib to download files
* used e.g. to dowload tiles * raises Blocked if we get a 403 and raises Not_Found on a 404, only if we get a Not_Found we try the next zoom level * in case we get blocked, it still tries the next tile... maybe we should stop trying to get tiles at all in that case
- Loading branch information
Showing
8 changed files
with
79 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
exception Failure of string | ||
exception Not_Found of string | ||
exception Blocked of string | ||
val file_of_url : ?dest:string -> string -> string | ||
(** [file_of_url ?dest url] Downloads a given document and returns | ||
the place where it is stored. Default [dest] is in [/tmp]. *) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters