ValidationInterface
in
Describes Validation interface.
Table of Contents
Methods
- getErrorCode() : int
- Retrieve last error code.
- getErrorMessage() : string
- Retrieve last error message.
- isValid() : bool
- Check if data is valid.
- validate() : static
- Validate the data using defined rules.
Methods
getErrorCode()
Retrieve last error code.
public
getErrorCode() : int
Return values
intgetErrorMessage()
Retrieve last error message.
public
getErrorMessage() : string
Return values
stringisValid()
Check if data is valid.
public
isValid(array<string, mixed> $Data) : bool
Parameters
- $Data : array<string, mixed>
-
The data to be validated.
Tags
Return values
boolvalidate()
Validate the data using defined rules.
public
validate(array<string, mixed> $Data) : static
Parameters
- $Data : array<string, mixed>
-
The data to be validated.