import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class demo1 {
/**java正则表达式
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
String email = "cingbo@ss.com";
Pattern patten = Pattern
.compile("[\w\.\-]+@([\w\-]+\.)+[\w\-]+");
Matcher matcher = patten.matcher(email);
System.out.println(matcher.matches());
}
}