DescriptionAdd Uri.isScheme test function.
Allows checking the scheme of a URI against a known value.
Example: `uri.isScheme("http")`.
Has two advantages over `uri.scheme == "http"`:
* It's case insensitive, so you can do `uri.isScheme("HTTP")` as well, and
* for simple URIs, it doesn't need to allocate a new string.
R=floitsch@google.com
Committed: https://github.com/dart-lang/sdk/commit/dd561d513bcecb20e5995eccdd3843d529c0ec5b
Patch Set 1 #
Total comments: 1
Patch Set 2 : Address comment. #
Messages
Total messages: 8 (3 generated)
|