Added abstraction layer to DataSources
This commit is contained in:
@@ -27,4 +27,14 @@ public final class FormattingUtil {
|
||||
public static String formatEuro(final double amount) {
|
||||
return String.format(Locale.GERMAN, "%,.2f", amount) + " €";
|
||||
}
|
||||
|
||||
/**
|
||||
* Makes a string URL ready. For now, only spaces are replaced.
|
||||
*
|
||||
* @param str
|
||||
* @return URL-ready string
|
||||
*/
|
||||
public static String urlEncode(final String str) {
|
||||
return str.replace(" ", "+");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user