Andre van Toly wrote:
> - return StringSplitter.split(getString(tag));
> + // return StringSplitter.split(getString(tag));
> + return Arrays.asList(getString(tag).split(","));
Are you sure that is actually the same? IIRC StringSplitter will also
'trim' its elements. In other words "a, b, c" became ["a", "b", "c"] and now
it will become ["a", " b", " c"] which is a different thing.
It should perhaps be split("\s*,\s*") then or so.
Indeed String.split is new in java 1.4, and StringSplitter was originally
implemented with StringTokenizer (which was a bit cumbersome, and therefore
someone came up with this StringSplitter util). I remember the introduction
of 'split' in the implementaiont of StringSplitter, it caused that that ""
becamee the list with one empty element rather then the empty list, which
one on or two spot also gave surprizing results. It seems such a trivial
task, isn't it :-)
Michiel
--
Michiel Meeuwissen mihxil'
Mediacentrum 140 H'sum [] ()
+31 (0)35 6772979 nl_NL eo_XX en_US
_______________________________________________
Developers mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/developers