class

Schematics::Field(T)

Inherits Schematics::BaseField / Reference / Object

Constructors

new(name : String, validator : Validator(T), required : Bool = true, default : T | Nil = nil, has_default_value : Bool = false)
Source

Instance methods

call(value) : T | Nil
Source
default
Source
get_default
Source
has_default?
Source
has_default_value
Source
validate(value, path : String) : ValidationResult
Source
validator
Source