How to check whether a file got read permissions for perticular user
807605May 25 2007 — edited Jun 13 2007Problem: Let JRE is running with some x as effective user in LINUX then while checking file permission it is checking permission on that file for that x user.
File f = new File(�file name�)
if(f.exists())
{
System.out.println(�exists�);
}
Else
{
System.out.println(�does not exists�);
}
The above code prints exists only when x user have permissions on that file
Requirement: I would like to check whether a file got read permissions for particular user i.e. whether y user got permissions on that file.
Any help is appreciated