API Reference Source
public class | source

ValidationErrorItem

Validation Error Item Instances of this class are included in the ValidationError.errors property.

Constructor Summary

Public Constructor
public

constructor(message: string, type: string, path: string, value: string, instance: Model, validatorKey: string, fnName: string, fnArgs: Array)

Creates a new ValidationError item.

Member Summary

Public Members
public

instance: Model | null

The DAO instance that caused the validation error

public

An error message

public

path: string | null

The field that triggered the validation error

public

type: string | null

The type/origin of the validation error

public

Parameters used with the BUILT-IN validator function, if applicable

public

validatorKey: string | null

A validation "key", used for identification

public

validatorName: string | null

Property name of the BUILT-IN validator function that caused the validation error (e.g.

public

value: string | null

The value that generated the error

Public Constructors

public constructor(message: string, type: string, path: string, value: string, instance: Model, validatorKey: string, fnName: string, fnArgs: Array) source

Creates a new ValidationError item. Instances of this class are included in the ValidationError.errors property.

Params:

NameTypeAttributeDescription
message string
  • optional

An error message

type string
  • optional

The type/origin of the validation error

path string
  • optional

The field that triggered the validation error

value string
  • optional

The value that generated the error

instance Model
  • optional

the DAO instance that caused the validation error

validatorKey string
  • optional

a validation "key", used for identification

fnName string
  • optional

property name of the BUILT-IN validator function that caused the validation error (e.g. "in" or "len"), if applicable

fnArgs Array
  • optional

parameters used with the BUILT-IN validator function, if applicable

Public Members

public instance: Model | null source

The DAO instance that caused the validation error

public message: string source

An error message

public path: string | null source

The field that triggered the validation error

public type: string | null source

The type/origin of the validation error

public validatorArgs: Array source

Parameters used with the BUILT-IN validator function, if applicable

public validatorKey: string | null source

A validation "key", used for identification

public validatorName: string | null source

Property name of the BUILT-IN validator function that caused the validation error (e.g. "in" or "len"), if applicable

public value: string | null source

The value that generated the error