class PaymentUtils {

    public static boolean matchesCurrencyPatternOrEmpty(@Nullable String priceString) {
        if (TextUtils.isEmpty(priceString)) {
            return true;
        }
        Pattern pattern = Pattern.compile("^-?[0-9]+(\\.[0-9][0-9])?");
        return pattern.matcher(priceString).matches();
    }

}