It is very surprising but I faced one problem using StringTokenizer class.
I used 2 parameter constructor i.e. StringTokenizer("This is my : first token ::: This is my : second token",":::");
Now in above case if I tokenize the string it gives me 4 tokens as
This is my
first token
This is my
second token
Instead it should give me
This is my : first token
This is my : second token
I am confused why it is tokenizing for single ':' as my seperator token is ':::'
Any body has idea ?
I used 2 parameter constructor i.e. StringTokenizer("This is my : first token ::: This is my : second token",":::");
Now in above case if I tokenize the string it gives me 4 tokens as
This is my
first token
This is my
second token
Instead it should give me
This is my : first token
This is my : second token
I am confused why it is tokenizing for single ':' as my seperator token is ':::'
Any body has idea ?