UrlValidationConfig class final

Configuration rules for URL validation.

Annotations
  • @immutable

Constructors

UrlValidationConfig({Set<String> allowedSchemes = const {'http', 'https'}, bool requireHost = true})
Creates a URL validation config.
const

Properties

allowedSchemes → Set<String>
Allowed schemes (e.g. http, https, ftp). Defaults to {'http', 'https'}.
final
hashCode → int
The hash code for this object.
no setteroverride
requireHost → bool
Whether to require a top-level domain or valid host name.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

copyWith({Set<String>? allowedSchemes, bool? requireHost}) → UrlValidationConfig
Returns a copy with the supplied fields replaced.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
override