Create directory using Java with certain permissions
Posted on 2008-10-31
I'm using java.io.File.makedirs() to create a directory on HP Unix. It creates a directory with permissions inherited from the user profile set by the Sys Admin. Problem is the directory is created with only read permission to the group but I want to provide write permissions as well. The class File does not provide any method to create the directory and set its permissions i.e to override the default permissions.
Is there any other way to achieve this i.e. create a directory at set its permissions as per wish.