
Quoting [Ceriel Jacobs] (Dec 04 2007):
Andre Merzky wrote:
Quoting [Ceriel Jacobs] (Dec 03 2007):
B: why the limitation to relative path names? Not really needed, indeed, but conceptually, wildcard expansion operates on a directory, and we are talking about methods on directories here.
Sorry for being thick: yes, they operate on a directory, but how does that imply relative paths? E.g., the following calls expand on the contents of a single directory, but would be impossible with relative paths:
rm /tmp/* cp /tmp/*/*.jpg /home/user/images/tmp/
Not impossible. In Java-speak:
NSDirectory tmp = new NSDirectory(session, new URL("/tmp"), ...); tmp.remove("*"); tmp.copy("*/*.jpg", new URL("/home/user/images/tmp/"), ...);
Right of course, you can always create an extra dir where the wildcard paths elements are relative to, or 'cd()' to thar dir. I did not think of that *blush*. I wonder if others do ;-) Andre. -- No trees were destroyed in the sending of this message, however, a significant number of electrons were terribly inconvenienced.