RegexPattern class Null safety
Strict Pattern
Symbol ^ and $ in pattern is to make sure all the string value following the pattern
Regex will return false if any of the character not following the pattern, even if using hasMatch function
Example: Pattern : Email -> 'This is your email : test@gmail.com' will return false
, but 'test@gmail.com' will return true
Constructors
Properties
- hashCode → int
-
The hash code for this object.
read-onlyinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
read-onlyinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- alphabetOnly ↔ String
-
Alphabet Only regex (No Whitespace & Symbols)
read / write
- alphaNumericOnly ↔ String
-
Alphabet & Numeric Only regex (No Whitespace & Symbols)
read / write
- alphaNumericSymbolOnly ↔ String
-
Alphabet, Numeric, Symbol Only regex (No Whitespace & Symbols)
read / write
- apk ↔ String
-
Document regex
read / write
- audio ↔ String
-
Audio regex
read / write
- basicDateTime ↔ String
-
DateTime regex (UTC)
Unformatted date time (UTC and Iso8601)
Example: 2020-04-27 08:14:39.977, 2020-04-27T08:14:39.977, 2020-04-27 01:14:39.977Z
read / write
- binary ↔ String
-
Binary regex
Consist only 0 & 1
read / write
- currency ↔ String
-
Currency regex
read / write
- doc ↔ String
-
Document regex
read / write
- email ↔ String
-
Email regex
read / write
- excel ↔ String
-
Excel regex
read / write
- github ↔ String
-
Github repository regex
read / write
- hexadecimal ↔ String
-
Hexadecimal regex
read / write
- html ↔ String
-
HTML regex
read / write
- image ↔ String
-
Image regex
read / write
- ipv4 ↔ String
-
IPv4 regex
read / write
- ipv6 ↔ String
-
IPv6 regex
read / write
- isbn ↔ String
-
ISBN 10 & 13 regex
read / write
- md5 ↔ String
-
MD5 regex
read / write
- numericOnly ↔ String
-
Numeric Only regex (No Whitespace & Symbols)
read / write
- passport ↔ String
-
Passport No. regex
read / write
- passwordEasy ↔ String
-
Password (Easy) Regex
Allowing all character except 'whitespace'
Minimum character: 8
read / write
- passwordEasyAllowedWhitespace ↔ String
-
Password (Easy) Regex
Allowing all character
Minimum character: 8
read / write
- passwordHard ↔ String
-
Password (Hard) Regex
Allowing all character except 'whitespace'
Must contains at least: 1 uppercase letter, 1 lowecase letter, 1 number, & 1 special character (symbol)
Minimum character: 8
read / write
- passwordHardAllowedWhitespace ↔ String
-
Password (Hard) Regex
Allowing all character
Must contains at least: 1 uppercase letter, 1 lowecase letter, 1 number, & 1 special character (symbol)
Minimum character: 8
read / write
- passwordNormal1 ↔ String
-
Password (Normal) Regex
Allowing all character except 'whitespace'
Must contains at least: 1 letter & 1 number
Minimum character: 8
read / write
- passwordNormal1AllowedWhitespace ↔ String
-
Password (Normal) Regex
Allowing all character
Must contains at least: 1 letter & 1 number
Minimum character: 8
read / write
- passwordNormal2 ↔ String
-
Password (Normal) Regex
Allowing LETTER and NUMBER only
Must contains at least: 1 letter & 1 number
Minimum character: 8
read / write
- passwordNormal2AllowedWhitespace ↔ String
-
Password (Normal) Regex
Allowing LETTER and NUMBER only
Must contains: 1 letter & 1 number
Minimum character: 8
read / write
- passwordNormal3 ↔ String
-
Password (Normal) Regex
Allowing all character except 'whitespace'
Must contains at least: 1 uppercase letter, 1 lowecase letter & 1 number
Minimum character: 8
read / write
- passwordNormal3AllowedWhitespace ↔ String
-
Password (Normal) Regex
Allowing all character
Must contains at least: 1 uppercase letter, 1 lowecase letter & 1 number
Minimum character: 8
read / write
- pdf ↔ String
-
PDF regex
read / write
- phone ↔ String
-
Phone Number regex
Must started by either, "0", "+", "+XX
read / write
- ppt ↔ String
-
PPT regex
read / write
- sha1 ↔ String
-
SHA1 regex
read / write
- sha256 ↔ String
-
SHA256 regex
read / write
- ssn ↔ String
-
SSN (Social Security Number) regex
read / write
- txt ↔ String
-
Txt regex
read / write
- url ↔ String
-
URL regex
Eg:
read / write
- username ↔ String
-
Username regex
Requires minimum 3 character
Allowing "_" and "." in middle of name
read / write
- vector ↔ String
-
Image vector regex
read / write
- video ↔ String
-
Video regex
read / write