Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static final String new_price = "((?:[0-9]{1,3}[\.,]?)*[\.,]?[0-9]+)";
- final Pattern p = Pattern.compile(new_price, 0);
- final Matcher m = p.matcher(label);
- if (m.matches()) {
- Log.d(TAG, "found! good start");
- if (m.groupCount() == 1) {
- Log.d(TAG, "start match price" + " : " + m.group(0));
- }
- if (m.groupCount() == 2) {
- Log.d(TAG, "start match price" + " : " + m.group(1));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement