Table of Contents

Class UrlValidator

Namespace
CloudyWing.FormValidators
Assembly
CloudyWing.FormValidators.dll

The URL validator.

public sealed class UrlValidator : BasicFormValidator, IFormValidator
Inheritance
UrlValidator
Implements
Inherited Members

Constructors

UrlValidator(string, string, Func<string, string, string>)

Initializes a new instance of the UrlValidator class.

public UrlValidator(string column, string value, Func<string, string, string> customErrorMessageAccessor = null)

Parameters

column string

The column.

value string

The value.

customErrorMessageAccessor Func<string, string, string>

The custom error message accessor. The arguments are column, value.

UrlValidator(string, string, UriKind, Func<string, string, string>)

Initializes a new instance of the UrlValidator class.

public UrlValidator(string column, string value, UriKind kind, Func<string, string, string> customErrorMessageAccessor = null)

Parameters

column string

The column.

value string

The value.

kind UriKind

The kind.

customErrorMessageAccessor Func<string, string, string>

The custom error message accessor. The arguments are column, value.

Properties

DefaultErrorMessageAccessor

Gets the get default error message.

protected override Func<string, string, string> DefaultErrorMessageAccessor { get; }

Property Value

Func<string, string, string>

The get default error message.

Kind

Gets the kind.

public UriKind Kind { get; }

Property Value

UriKind

The kind.

Methods

ValidateValue()

Validates the value.

protected override bool ValidateValue()

Returns

bool

The validation result.