Class Validator
- Namespace
- Dynamicweb.Content.Items.Editors
- Assembly
- Dynamicweb.dll
Represents a validator.
public abstract class Validator
- Inheritance
-
Validator
- Inherited Members
Constructors
Validator()
Initializes a new instance of an object.
protected Validator()
Properties
ErrorMessage
Gets or sets the error message displayed when validation fails.
public string ErrorMessage { get; set; }
Property Value
Methods
RenderValidator(string, EditFormField)
Render validation script.
[Obsolete("Do not use")]
public virtual string RenderValidator(string context, EditFormField field)
Parameters
context
string- Validation context.
field
EditFormField- Field.
Returns
- string
- Value indicating whether validation was successful.
RenderValidator(string, ItemField)
Render validation script.
[Obsolete("Do not use")]
public virtual string RenderValidator(string context, ItemField fieldMeta)
Parameters
Returns
- string
- Value indicating whether validation was successful.
Validate(ValidatorContext)
Performs validation and returns value indicating whether validation was successful.
public abstract bool Validate(ValidatorContext context)
Parameters
context
ValidatorContext- Validation context.
Returns
- bool
- Value indicating whether validation was successful.