[][src]Module valid::property

Property traits

This module defines property traits that enable the generic implementation of the Validate trait of the provided constraints.

Property traits are one way to derive an implementation of Validate trait for a custom type. For example if we have a custom type that represents some kind of decimal number for which we implement the HasDecimalDigits trait we can use the existing implementation of the Validate trait for the Digits constraint and our custom type.

Traits

HasCharCount

The number of characters property of a type.

HasCheckedValue

The checked property of a type.

HasDecimalDigits

Properties of a decimal number.

HasEmptyValue

The empty property of a type.

HasLength

The length property of a type.

HasMember

Determines whether the given element is part of a value or member of a collection.

HasZeroValue

Defines that a type has a zero value.