Kev, I'd have expected the reflection to be on the new File method in
jdk6, not on an Ant class that depends on jdk6+. Because this means
this new Ant class must be compiled with jdk6+, or cross-compiled
against a jdk6+ rt.jar.
True, I hadn't considered that, my focus was entirely on maintaining a
clean build on pre java6 vms, without considering if the code was
actually compiled.
So more something like (assuming a File#freeSpace method):
> + ReflectWrapper w = new ReflectWrapper(..., "java.io.File");
> + long free = ((Long)w.invoke("freeSpace", String.class,
partition)).longValue();
> + return free >= StringUtils.parseHumanSizes(needed);
I'll try some variations of this to see if I can get it to work as suggested.
Thanks
Kev
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]