+
+ /**
+ * Check the delimiter for proper regular expression matching
+ * @param inDelim character selected as delimiter
+ * @return regular expression for splitting
+ */
+ private static String checkDelimiter(char inDelim)
+ {
+ String result = "" + inDelim;
+ // Don't pass asterisks or dots without escaping them for RE
+ if (inDelim == '*' || inDelim == '.') {
+ result = "\\" + result;
+ }
+ return result;
+ }