Regular expressions are the key to powerful, flexible, and efficient text processing. It allows us to describe and parse text. Regular expressions can add, remove, isolate, and generally fold, spindle, and mutilate all kinds of text and data.
1. Getting Started
2. Working with Regex
- Match Any Character(s)
- Match Start or End of String (Line Anchors)
- Remove non-printable non-ASCII characters
- Match Word with All Misspellings
- Limit the number of lines in the text
- Limit the number of words in the input
- Check Min/Max Length of Input Text
- Allow only alphanumeric characters
- Date validation using RegEx
- Java regex word boundary – match a specific word or contain words
- Java regex word boundary – match the lines that starts with and ends with pattern
3. Commonly Used Patterns
- Credit Card Number Validation
- UK Postal Code Validation
- Canada Postal Code Validation
- US Zip Code Validation
- Trademark Symbol Validation
- Email Validation
- Password Validation
- Validate ISBN (International Standard Book Number)
- Validate SSN (Social Security Numbers)
- Validate International Phone Numbers
- Validate North American Phone Numbers
- Validate Greek Extended or Greek Script
- Validate Currency Symbols
Happy Learning !!