Returns a boolean indicating whether this file can be found on the underlying file system. @return true if this file exists, false otherwise. @throws SecurityException if a SecurityManager is installed and it denies read access to this file. @see #get
()
| 442 | * @see java.lang.SecurityManager#checkRead(FileDescriptor) |
| 443 | */ |
| 444 | public boolean exists() { |
| 445 | if (path.length() == 0) { |
| 446 | return false; |
| 447 | } |
| 448 | // SecurityManager security = System.getSecurityManager(); |
| 449 | // if (security != null) { |
| 450 | // security.checkRead(path); |
| 451 | // } |
| 452 | return existsImpl(properPath(true)); |
| 453 | } |
| 454 | |
| 455 | private native boolean existsImpl(byte[] filePath); |
| 456 |
no test coverage detected