Class Util
java.lang.Object
org.sblim.cimclient.internal.util.Util
Class Util is responsible for storing commonly used static methods.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic String[]getFilteredStringArray(String[] pArray, String pIgnoreElements) Filters any elements listed inpIgnoreElementsout ofpArrayand returns the updated array.static booleanisBadDoubleString checks if passed string could hang JVM.static StringQuotes the passed string.
-
Constructor Details
-
Util
public Util()
-
-
Method Details
-
quote
-
isBadDoubleString
isBadDoubleString checks if passed string could hang JVM.- Parameters:
s- A string to be converted to a Double.- Returns:
trueif double is in range of bad values,falseotherwise.
-
getFilteredStringArray
Filters any elements listed inpIgnoreElementsout ofpArrayand returns the updated array. For example, ifpArray = {"A", "B", "C", "D", "E", "F", "G"}andpIgnoreElements = "D,E,B"then this method returns{"A", "C", "F", "G"}.- Parameters:
pArray- Original string array.pIgnoreElements- Comma-separated list of array elements to ignore.- Returns:
- Updated string array.
-