Java正则表达式

		try{
			Pattern pattern = Pattern.compile("(([0-9]+)+.([0-9]+))|([0-9]+)");
			
			String s = "12312dfasesesd22.233";
			
			Matcher matcher = pattern.matcher(s);
			
			System.out.println("aaa");
			while (matcher.find()){
				System.out.println(matcher.group());
			}
			
		} catch(Exception e){
			e.printStackTrace();
		}

你可能感兴趣的:(Java正则表达式)