src/validation/validation.model.ts
Properties |
Methods |
|
constructor(type: ValidationType, message: string)
|
||||||||||||
Defined in src/validation/validation.model.ts:3
|
||||||||||||
Parameters :
|
Public isRequired |
isRequired()
|
Defined in src/validation/validation.model.ts:10
|
Returns :
boolean
|
Public message |
message:
|
Type : string
|
Defined in src/validation/validation.model.ts:7
|
Public type |
type:
|
Type : ValidationType
|
Defined in src/validation/validation.model.ts:6
|
import { ValidationType } from '.';
export abstract class Validation {
public constructor(
public type: ValidationType,
public message: string
) { }
public isRequired(): boolean {
return ValidationType.REQUIRED === this.type;
}
}