|
Your problem with using temp.split("||"); is simply that the argument is a regular expression not a string, char, or char array. You must give it the escape character which must be escaped itself. Use the following line to do it without replacing your || with something else:
temp.split("\\|\\|");
|