How to: Just write what you desired (it's magic). Example: validate an email
^[w-.]+@([w-]+.)+[w-]{2,4}$