Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

IsDefined

  • IsDefined(validationOptions?: ValidationOptions): (object: any, propertyName: string) => void
  • Decorator that checks if the property is defined (Not null or undefined).

    Example

    class IsDefinedDemo {
    @IsDefined()
    d:any = 'defined'
    }

    Parameters

    Returns (object: any, propertyName: string) => void

      • (object: any, propertyName: string): void
      • Parameters

        • object: any
        • propertyName: string

        Returns void

validateArray

validateValue

  • Value is valid if it passes the {@link isDefined} check.

    Parameters

    • vc: ValidationContext

      The validation context.

    • o: any

      The object containing the property to validate.

    Returns boolean

    True if the value is not null or undefined, false otherwise.

Generated using TypeDoc