createListFromUri static method
Creates a SuffixRules
object using a suffix list resource obtained from a URI.
See SuffixRules.fromString for the expected format of the suffix list.
HttpRequest.request is used to retrieve the resource, and the optional parameters can be used to tweak this request. If more fine-grained control over the request is needed, consider obtaining the suffix list using custom code first and then passing it to SuffixRules.fromString.
An Exception is thrown if the request fails.
Implementation
static Future<SuffixRules> createListFromUri(Uri uri,
{bool? withCredentials,
Map<String, String>? requestHeaders,
dynamic sendData,
void Function(ProgressEvent)? onProgress}) async {
return SuffixRules.fromString(await _getUri(uri,
withCredentials: withCredentials,
requestHeaders: requestHeaders,
sendData: sendData,
onProgress: onProgress));
}