| 103 | |
| 104 | |
| 105 | Future<Nothing> Fetcher::fetch( |
| 106 | const URI& uri, |
| 107 | const string& directory, |
| 108 | const Option<string>& data, |
| 109 | const Option<string>& outputFileName) const |
| 110 | { |
| 111 | if (!pluginsByScheme.contains(uri.scheme())) { |
| 112 | return Failure("Scheme '" + uri.scheme() + "' is not supported"); |
| 113 | } |
| 114 | |
| 115 | return pluginsByScheme.at(uri.scheme())->fetch( |
| 116 | uri, |
| 117 | directory, |
| 118 | data, |
| 119 | outputFileName); |
| 120 | } |
| 121 | |
| 122 | |
| 123 | Future<Nothing> Fetcher::fetch( |