I just wrote a test program for these new methods in Java 1.6 and they work great. You are right that they don't give you full granularity into user, group, and other, but they do allow setting just the user or everybody (which sets user, group, and other). I think that is sufficient for my needs.
--- Shawn Castrianni -----Original Message----- From: Stefan Bodewig [mailto:[email protected]] Sent: Tuesday, March 03, 2009 10:44 PM To: [email protected] Subject: Re: zip/tar and file permissions On 2009-03-03, Shawn Castrianni <[email protected]> wrote: > Java 1.6 seems to have available: > canRead > canWrite > canExecute (new to 1.6) > setReadable (new to 1.6) > setWritable (new to 1.6) > setExecutable (new to 1.6) which is insufficient since it only get/sets the bits for the current user and not the owner/group or "other" permissions on Unix. > which makes me think this is now possible to do in a platform > independent way from ANT. If Ant wouldn't target JDK 1.4, that is 8-) Yes, it would be possible to have a Java 6+ extension of zip/tarfileset that could try to autodetect settings, agreed. Want to file an enhancement request in bugzilla? If you wanted to implement it, that would be even better. Stefan --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] ---------------------------------------------------------------------- This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient. Any review, use, distribution, or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive information for the intended recipient), please contact the sender by reply e-mail and delete all copies of this message. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
