static boolean hasDiskAccess ( final String path ) { try { AccessController . checkPermission ( new FilePermission ( path , "read,write" ) ) ; return true ; } catch ( AccessControlException e ) { return false ; } }
Checks for disk access .