This method attempts to match a given regular expression against the complete subject String and returns true/false, indicating whether the match is successful or not. The following are a few important points to note:
- Regular expression is applied against the entire String; there is no partial matching
- Regular expression does not need to be anchored using ^ and $, since it is matched against the entire input
- The equivalent of Pattern.matches(String regex, CharSequenceinput) method (will be covered later)