Hi,
+-From: "Oberhuber, Martin" <[EMAIL PROTECTED]> --
|_Date: Thu, 27 Sep 2007 18:08:41 +0200 _______________________
|
>> As for filename globbing operation, String.getBytes("UTF-8")
>> will be enought.
|Why are you against String.toCharArray() ? Do you fear about
|performance when dealing with 16-bit chars?
No, there is not a deep reason.
There exists isPattern(byte[] str) already.
|very simple operation. Actually, I'd propose doing both
|isPattern() and unquote() in a single method call, encaptured
|in a local static class - then a single iteration over the
|String is sufficient:
|private static class Unquoter {
| boolean isPattern = false;
| boolean wasQuoted = false;
| StringBuffer buf;
| public Unquoter(String s) {
| buf = new StringBuffer(s.length());
| for(int i=0; i<s.length(); i++) {
| }
| }
| public boolean isPattern() { return isPattern; }
| public boolean wasQuoted() { return wasQuoted; }
| public String getUnQuoted() { return buf.toString(); }
|}
Thank you for your suggestion.
If there is an opportunity, it may be used.
Sincerely,
--
Atsuhiko Yamanaka
JCraft,Inc.
1-14-20 HONCHO AOBA-KU,
SENDAI, MIYAGI 980-0014 Japan.
Tel +81-22-723-2150
+1-415-578-3454
Fax +81-22-224-8773
Skype callto://jcraft/
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
JSch-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jsch-users