0

Hi,

Can you help me in identifiying the meaning of this reqular expression?
public static final Pattern pattern = Pattern.compile("^.(?=.{8,})(?=.[a-z])(?=.[A-Z])(?=.[\W_]).*$");

Thanks,
Aravind

2
Contributors
1
Reply
15
Views
1 Year
Discussion Span
Last Post by cereal
1

Hi,

go to http://regexr.com/3eb88 and mousehover the components of the expression (or hit the Explain tab), it will explain the meaning of each block. If you have some sample data you can paste it in their form and see how it is applied.

For example, try to change [\W_] to [\w] to see what is parsed.

Edited by cereal

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.