[][src]Crate rfc2396

To use this crate, simply call one of the validate* functions, depending on your use case and desired return type:

Where S is some type that implements Into<&str>; for example, &str itself!

All functions except the _nom variant will additionally ensure that the entire input is consumed and matches exactly what was parsed internally. If you require that this check is not done (e.g. as part of a larger parsing exercise), then use the _nom variant.

Functions

validate

Validate the given URI against RFC2396, returning a bool indicating its validity.

validate_nom

Validate the given URI against RFC2396, returning a nom::IResult<&str, &str> indicating its validity.

validate_opt

Validate the given URI against RFC2396, returning an Option<&str> indicating its validity.

validate_res

Validate the given URI against RFC2396, returning an anyhow::Result<&str> indicating its validity.