java.io.File and properties
Brian Jones
cbj@gnu.org
Sun May 11 15:12:00 GMT 2003
"Ranjit Mathew" <rmathew4lists@hotmail.com> writes:
> > The above from Sun looks stupid. At what point is it useful to allow
> > programmer's to modify tmpdir at runtime but not let that change the
> > way createTempFile works? I guess we can be bug compatible here, but
> > we may need a gnu.java.io.File.getTempDir() that works better.
>
> BTW, I should note that the output is unchanged if I use
> System.setProperty( ) instead of put( ).
>
> Similarly, 'new File( ".").listFiles( )' is unaffected by
> any value I set for "user.dir".
Yes, you have to use JNI to actually modify the CWD under Java. I
think because some system some where that has a file system doesn't
necessarily have a CWD concept. Annoys you when you really would like
to do this.
Brian
--
Brian Jones <cbj@gnu.org>
More information about the Java
mailing list