2 package org
.de
.metux
.util
;
6 import java
.util
.StringTokenizer
;
10 splits an command line into an array of strings.
12 FIXME: currently no quotes and escapes supported.
16 public class CmdLineSplitter
18 public static String
[] split(String str
)
20 /* with current versions of libgcj we need to use the StringTokenizer,
21 since regex support is missing */
23 str
= StrReplace
.replace("\\ ","++++++++++++",str
).trim();
28 String args
[] = str
.split(" ");
29 for (int x
=0; x
<args
.length
; x
++)
30 args
[x
] = StrReplace
.replace("++++++++++++", " ", args
[x
]);