Add support for  regular expressions

Add support for regular expression validation. The regular expression is variable, the the check is a fast .test method.