Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

IsValueIn

  • IsValueIn(target: any[], validationOptions?: ValidationOptions): (object: any, propertyName: string) => void
  • Decorator that checks if the array value is in the array of values.

    Example

    class IsUUIDDemo {
    @IsUUID()
    alpha:string = 'A987FBC9-4BED-3078-CF07-9141BA07C9F3'
    }

    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 is in the target array.

    Parameters

    • vc: ValidationContext

      The validation context.

    • o: any

      The object containing the property to validate.

    Returns boolean

    True if the value is in the target array.

Generated using TypeDoc