| java.lang.Object org.ofbiz.base.util.UtilMisc
UtilMisc | public class UtilMisc (Code) | | UtilMisc - Misc Utility Functions
|
Method Summary | |
public static void | addToBigDecimalInMap(Map theMap, Object mapKey, BigDecimal addNumber) | public static void | addToDoubleInMap(Map theMap, Object key, Double value) | public static List | availableLocales() | public static Locale | ensureLocale(Object localeObject) The input can be a String, Locale, or even null and a valid Locale will always be returned; if nothing else works, returns the default locale. | public static List | getListFromMap(Map outerMap, Object key) | public static Map | getMapFromMap(Map outerMap, Object key) | public static Locale | parseLocale(String localeString) | public static String | printMap(Map theMap) | public static Object | removeFirst(List lst) | public static List | sortMaps(List listOfMaps, List sortKeys) Sort a List of Maps by specified consistent keys.
Parameters: listOfMaps - List of Map objects to sort. Parameters: sortKeys - List of Map keys to sort by. | public static double | toDouble(Object value) | public static Iterator | toIterator(Collection col) | public static List | toList(Object obj1) | public static List | toList(Object obj1, Object obj2) | public static List | toList(Object obj1, Object obj2, Object obj3) | public static List | toList(Object obj1, Object obj2, Object obj3, Object obj4) | public static List | toList(Object obj1, Object obj2, Object obj3, Object obj4, Object obj5) | public static List | toList(Object obj1, Object obj2, Object obj3, Object obj4, Object obj5, Object obj6) | public static List | toList(Collection collection) | public static List | toListArray(Object[] data) | public static long | toLong(Object value) | public static Map | toMap(String name1, Object value1) | public static Map | toMap(String name1, Object value1, String name2, Object value2) | public static Map | toMap(String name1, Object value1, String name2, Object value2, String name3, Object value3) | public static Map | toMap(String name1, Object value1, String name2, Object value2, String name3, Object value3, String name4, Object value4) | public static Map | toMap(String name1, Object value1, String name2, Object value2, String name3, Object value3, String name4, Object value4, String name5, Object value5) | public static Map | toMap(String name1, Object value1, String name2, Object value2, String name3, Object value3, String name4, Object value4, String name5, Object value5, String name6, Object value6) | public static Map | toMap(Object[] data) |
availableLocaleList | public static List availableLocaleList(Code) | | |
addToBigDecimalInMap | public static void addToBigDecimalInMap(Map theMap, Object mapKey, BigDecimal addNumber)(Code) | | Assuming theMap not null; if null will throw a NullPointerException
|
addToDoubleInMap | public static void addToDoubleInMap(Map theMap, Object key, Double value)(Code) | | Adds value to the key entry in theMap, or creates a new one if not already there
Parameters: theMap - Parameters: key - Parameters: value - |
availableLocales | public static List availableLocales()(Code) | | Returns a List of available locales sorted by display name
|
ensureLocale | public static Locale ensureLocale(Object localeObject)(Code) | | The input can be a String, Locale, or even null and a valid Locale will always be returned; if nothing else works, returns the default locale.
Parameters: localeObject - An Object representing the locale |
getListFromMap | public static List getListFromMap(Map outerMap, Object key)(Code) | | Assuming outerMap not null; if null will throw a NullPointerException
|
getMapFromMap | public static Map getMapFromMap(Map outerMap, Object key)(Code) | | Assuming outerMap not null; if null will throw a NullPointerException
|
parseLocale | public static Locale parseLocale(String localeString)(Code) | | Parse a locale string Locale object
Parameters: localeString - The locale string (en_US) Locale The new Locale object or null if no valid locale can be interpreted |
sortMaps | public static List sortMaps(List listOfMaps, List sortKeys)(Code) | | Sort a List of Maps by specified consistent keys.
Parameters: listOfMaps - List of Map objects to sort. Parameters: sortKeys - List of Map keys to sort by. a new List of sorted Maps. |
toDouble | public static double toDouble(Object value)(Code) | | Returns a double from value, where value could either be a Double or a String
Parameters: value - |
toIterator | public static Iterator toIterator(Collection col)(Code) | | Get an iterator from a collection, returning null if collection is null
Parameters: col - The collection to be turned in to an iterator The resulting Iterator |
toList | public static List toList(Object obj1)(Code) | | Create a list from passed objX parameters
The resulting List |
toList | public static List toList(Object obj1, Object obj2)(Code) | | Create a list from passed objX parameters
The resulting List |
toMap | public static Map toMap(String name1, Object value1)(Code) | | Create a map from passed nameX, valueX parameters
The resulting Map |
toMap | public static Map toMap(String name1, Object value1, String name2, Object value2, String name3, Object value3, String name4, Object value4, String name5, Object value5)(Code) | | Create a map from passed nameX, valueX parameters
The resulting Map |
toMap | public static Map toMap(String name1, Object value1, String name2, Object value2, String name3, Object value3, String name4, Object value4, String name5, Object value5, String name6, Object value6)(Code) | | Create a map from passed nameX, valueX parameters
The resulting Map |
toMap | public static Map toMap(Object[] data)(Code) | | Create a map from passed nameX, valueX parameters
The resulting Map |
|
|