@SuppressWarnings("unchecked") public static String[] split(String original,String separator){
  nodes.removeAllElements();
  int index=original.indexOf(separator);
  while (index >= 0) {
    nodes.addElement(original.substring(0,index));
    original=original.substring(index + separator.length());
    index=original.indexOf(separator);
  }
  nodes.addElement(original);
  String[] result=new String[nodes.size()];
  if (nodes.size() > 0) {
    for (int loop=0; loop < nodes.size(); loop++) {
      result[loop]=(String)nodes.elementAt(loop);
    }
  }
  return result;
}

@ SuppressWarnings ( "unchecked" ) public static String [ ] split ( String original , String separator ) { nodes . removeAllElements ( ) ; int index = original . indexOf ( separator ) ; while ( index >= 0 ) { nodes . addElement ( original . substring ( 0 , index ) ) ; original = original . substring ( index + separator . length ( ) ) ; index = original . indexOf ( separator ) ; } nodes . addElement ( original ) ; String [ ] result = new String [ nodes . size ( ) ] ; if ( nodes . size ( ) > 0 ) { for ( int loop = 0 ; loop < nodes . size ( ) ; loop ++ ) { result [ loop ] = ( String ) nodes . elementAt ( loop ) ; } } return result ; }
split string into multiple strings .
