Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

parsing comma delimited string

 
jimbo jawgar
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I there a class & method to parse a comma delimited string
Something like
SomeClass sc = new SomeClass("abc,efg,hij");
String s = sc(1,",");
System.out.println(s)

abc

Thanks


String method split(",") worked fine. Thanks alot
[ November 02, 2004: Message edited by: jimbo jawgar ]
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
StringTokenizer(), or, if you have java 1.4+, String.split()
 
Anand Karia
Ranch Hand
Posts: 156
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hope this will work out for you.

 
Shailesh Chandra
Ranch Hand
Posts: 1082
Java Oracle Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
also refer to this thread
[ November 03, 2004: Message edited by: Shailesh Chandra ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic