String Tokenizer

Hi people,

I have a string (I read it from a file) that I want to breakup into smaller strings using the tab character as the delimeter; i.e. there is data in the file separated by tabs. Now when the data for a specific entry is not present there will be two tabs at the location; signifying that the specific entry is to be considered blank.

But when consecutive tokens are encountered the StringTokenizer class treats them as a single token. What I've done is that I have replaced every "\t\t" with a "\t \t" (putting a space between them) on the whole string; BUT this is very expensive as the size of the file is very large.

Dose anyone have any idea about any other better approach to handle this problem

Thank you

Omer

[769 byte] By [Oaq] at [2007-9-26 4:40:18]
# 1
http://forum.java.sun.com/thread.jsp?forum=31&thread=158421
schillj at 2007-6-29 18:01:39 > top of Java-index,Archived Forums,Java Programming...