MetaFoxPasswordFormatRule
in package
implements
Rule
Class MetaFoxPasswordFormatRule.
Table of Contents
Interfaces
- Rule
Constants
- LOWERCASE_CHARACTER_PATTERN = '/[a-z]/'
- Lower character pattern for a strong password.
- NUMBER_PATTERN = '/[0-9]/'
- Number pattern for a strong password.
- SPECIAL_CHARACTER_PATTERN = '/[!"#$%&\'()*+,\\-.\\/:;<=>?@[\\]^_`{|}~]/'
- Special character pattern for a strong password.
- UPPERCASE_CHARACTER_PATTERN = '/[A-Z]/'
- Uppercase character pattern for a strong password.
Methods
- getFormRules() : array<string|int, mixed>
- getRequestRules() : array<string|int, mixed>
- getStrongPasswordFormRule() : array<string|int, mixed>
- isStrongPassword() : bool
- message() : string
- Get the validation error message.
- passes() : bool
- Determine if the validation rule passes.
- getLowerCaseRule() : string
- getMaxLengthRule() : string
- getMinLengthRule() : string
- getNumberRule() : string
- getSpecialCharactersRule() : string
- getUpperCaseRule() : string
Constants
LOWERCASE_CHARACTER_PATTERN
Lower character pattern for a strong password.
public
mixed
LOWERCASE_CHARACTER_PATTERN
= '/[a-z]/'
NUMBER_PATTERN
Number pattern for a strong password.
public
mixed
NUMBER_PATTERN
= '/[0-9]/'
SPECIAL_CHARACTER_PATTERN
Special character pattern for a strong password.
public
mixed
SPECIAL_CHARACTER_PATTERN
= '/[!"#$%&\'()*+,\\-.\\/:;<=>?@[\\]^_`{|}~]/'
UPPERCASE_CHARACTER_PATTERN
Uppercase character pattern for a strong password.
public
mixed
UPPERCASE_CHARACTER_PATTERN
= '/[A-Z]/'
Methods
getFormRules()
public
getFormRules() : array<string|int, mixed>
Return values
array<string|int, mixed>getRequestRules()
public
getRequestRules() : array<string|int, mixed>
Return values
array<string|int, mixed>getStrongPasswordFormRule()
public
getStrongPasswordFormRule() : array<string|int, mixed>
Return values
array<string|int, mixed>isStrongPassword()
public
isStrongPassword() : bool
Return values
boolmessage()
Get the validation error message.
public
message() : string
Return values
stringpasses()
Determine if the validation rule passes.
public
passes(string $attribute, mixed $value) : bool
Parameters
- $attribute : string
- $value : mixed
Tags
Return values
boolgetLowerCaseRule()
protected
getLowerCaseRule() : string
Return values
stringgetMaxLengthRule()
protected
getMaxLengthRule() : string
Return values
stringgetMinLengthRule()
protected
getMinLengthRule() : string
Return values
stringgetNumberRule()
protected
getNumberRule() : string
Return values
stringgetSpecialCharactersRule()
protected
getSpecialCharactersRule() : string
Return values
stringgetUpperCaseRule()
protected
getUpperCaseRule() : string