import { Severity } from "../shared/Severity" ; export class ValidationFailure { readonly target : any ; readonly propertyName : string ; readonly attemptedValue : any ; readonly code : string | undefined ; readonly message : string | undefined ; readonly severity : string ; constructor ( target , propertyName , attemptedValue ? , code ? , message ? , severity = Severity . ERROR ) { this . target = target ; this . propertyName = propertyName ; this . attemptedValue = attemptedValue ; this . code = code ; this . message = message ; this . severity = Severity [ severity ] ; } }