Table of Contents

Class FieldValidationRule

Namespace
Honua.Sdk.Field.Forms
Assembly
Honua.Sdk.Field.dll

Validation constraints applied to a field.

public sealed record FieldValidationRule : IEquatable<FieldValidationRule>
Inheritance
FieldValidationRule
Implements
Inherited Members

Properties

ConstraintExpression

Optional boolean constraint expression evaluated against the record values. Validation fails when the expression evaluates falsey. Within the expression the field's own value is addressable as . (and as $thisFieldId). Example: . >= 0 and . <= 100.

public string? ConstraintExpression { get; init; }

Property Value

string

ConstraintMessage

Optional message reported when ConstraintExpression fails.

public string? ConstraintMessage { get; init; }

Property Value

string

MaxLength

Maximum string length.

public int? MaxLength { get; init; }

Property Value

int?

MaxMediaCount

Maximum media attachment count allowed for media fields.

public int? MaxMediaCount { get; init; }

Property Value

int?

MaxNumericValue

Maximum numeric value, inclusive.

public double? MaxNumericValue { get; init; }

Property Value

double?

MinLength

Minimum string length.

public int? MinLength { get; init; }

Property Value

int?

MinMediaCount

Minimum media attachment count required for media fields.

public int? MinMediaCount { get; init; }

Property Value

int?

MinNumericValue

Minimum numeric value, inclusive.

public double? MinNumericValue { get; init; }

Property Value

double?

RegexPattern

Regular expression pattern the value must match.

public string? RegexPattern { get; init; }

Property Value

string