Regex Java Walidacja e -mail
System.out.println("E-Mail Adressen: " + emailAdressen("[email protected]"));
public static boolean emailAdressen(String emailAdressen) {
Pattern pattern = Pattern.compile("^[A-Z0-9_!#$%&'*+/=?`{|}~^-]+(?:\\.[A-Z0-9_!#$%&'*+/=?`{|}~^-]+↵\n" +
")*@[A-Z0-9-]+(?:\\.[A-Z0-9-]+)*$", Pattern.CASE_INSENSITIVE);
Matcher matcher = pattern.matcher(emailAdressen);
return matcher.find();
}
AttractivePenguin