Regular Expression (Pattern Matching)
Hi all, am trying to interpret the following
and my interpretation is
errors.add("name",new ActionMessage("email.invalid") );
Have a question, does these dots [\.] within brackets suggests that i can have dots in my address i.e email@example.com ?
^[a-zA-Z] must start with a letter(s)
[\\w\\.-]* can be followed by a number of characters including/ending with a dot or hyphen
[a-zA-Z0-9]@ must have a letter(s) and should be followed by '@'
[a-zA-Z0-9][\\w\\.-]*[a-zA-Z0-9] same as above (a string which may contain a dot or hyphen
\\. a dot must exist
[a-zA-Z][a-zA-Z\\.]*[a-zA-Z]$" a string which may contain a dot but must end with word characters