Replicating String.split with StringTokenizer

后端 未结 9 1059
心在旅途
心在旅途 2021-02-06 14:03

Encouraged by this, and the fact I have billions of string to parse, I tried to modify my code to accept StringTokenizer instead of String[]

The only t

9条回答
  •  执笔经年
    2021-02-06 14:58

    I would recommend Google's Guava Splitter.
    I compared it with coobird test and got following results:

    StringTokenizer 104
    Google Guava Splitter 142
    String.split 446
    regexp 299

提交回复
热议问题