905 * addition it checks 906 * {@link RuntimePermission}{@code ("getFileStoreAttributes")} 907 */ 908 public abstract FileStore getFileStore(Path path) throws IOException; 909 910 /** 911 * Checks the existence, and optionally the accessibility, of a file. 912 * 913 * <p> This method may be used by the {@link Files#isReadable isReadable}, 914 * {@link Files#isWritable isWritable} and {@link Files#isExecutable 915 * isExecutable} methods to check the accessibility of a file. 916 * 917 * <p> This method checks the existence of a file and that this Java virtual 918 * machine has appropriate privileges that would allow it access the file 919 * according to all of access modes specified in the {@code modes} parameter 920 * as follows: 921 * 922 * <table class="striped"> 923 * <caption style="display:none">Access Modes</caption> 924 * <thead> 925 * <tr> <th>Value</th> <th>Description</th> </tr> 926 * </thead> 927 * <tbody> 928 * <tr> 929 * <td> {@link AccessMode#READ READ} </td> 930 * <td> Checks that the file exists and that the Java virtual machine has 931 * permission to read the file. </td> 932 * </tr> 933 * <tr> 934 * <td> {@link AccessMode#WRITE WRITE} </td> 935 * <td> Checks that the file exists and that the Java virtual machine has 936 * permission to write to the file, </td> 937 * </tr> 938 * <tr> 939 * <td> {@link AccessMode#EXECUTE EXECUTE} </td> 940 * <td> Checks that the file exists and that the Java virtual machine has 941 * permission to {@link Runtime#exec execute} the file. The semantics 942 * may differ when checking access to a directory. For example, on UNIX 943 * systems, checking for {@code EXECUTE} access checks that the Java 944 * virtual machine has permission to search the directory in order to 945 * access file or subdirectories. </td> 946 * </tr> 947 * </tbody> 948 * </table> 949 * 950 * <p> If the {@code modes} parameter is of length zero, then the existence 951 * of the file is checked. 952 * 953 * <p> This method follows symbolic links if the file referenced by this 954 * object is a symbolic link. Depending on the implementation, this method 955 * may require to read file permissions, access control lists, or other 956 * file attributes in order to check the effective access to the file. To 957 * determine the effective access to a file may require access to several 958 * attributes and so in some implementations this method may not be atomic 959 * with respect to other file system operations. | 905 * addition it checks 906 * {@link RuntimePermission}{@code ("getFileStoreAttributes")} 907 */ 908 public abstract FileStore getFileStore(Path path) throws IOException; 909 910 /** 911 * Checks the existence, and optionally the accessibility, of a file. 912 * 913 * <p> This method may be used by the {@link Files#isReadable isReadable}, 914 * {@link Files#isWritable isWritable} and {@link Files#isExecutable 915 * isExecutable} methods to check the accessibility of a file. 916 * 917 * <p> This method checks the existence of a file and that this Java virtual 918 * machine has appropriate privileges that would allow it access the file 919 * according to all of access modes specified in the {@code modes} parameter 920 * as follows: 921 * 922 * <table class="striped"> 923 * <caption style="display:none">Access Modes</caption> 924 * <thead> 925 * <tr> <th scope="col">Value</th> <th scope="col">Description</th> </tr> 926 * </thead> 927 * <tbody> 928 * <tr> 929 * <th scope="row"> {@link AccessMode#READ READ} </th> 930 * <td> Checks that the file exists and that the Java virtual machine has 931 * permission to read the file. </td> 932 * </tr> 933 * <tr> 934 * <th scope="row"> {@link AccessMode#WRITE WRITE} </th> 935 * <td> Checks that the file exists and that the Java virtual machine has 936 * permission to write to the file, </td> 937 * </tr> 938 * <tr> 939 * <th scope="row"> {@link AccessMode#EXECUTE EXECUTE} </th> 940 * <td> Checks that the file exists and that the Java virtual machine has 941 * permission to {@link Runtime#exec execute} the file. The semantics 942 * may differ when checking access to a directory. For example, on UNIX 943 * systems, checking for {@code EXECUTE} access checks that the Java 944 * virtual machine has permission to search the directory in order to 945 * access file or subdirectories. </td> 946 * </tr> 947 * </tbody> 948 * </table> 949 * 950 * <p> If the {@code modes} parameter is of length zero, then the existence 951 * of the file is checked. 952 * 953 * <p> This method follows symbolic links if the file referenced by this 954 * object is a symbolic link. Depending on the implementation, this method 955 * may require to read file permissions, access control lists, or other 956 * file attributes in order to check the effective access to the file. To 957 * determine the effective access to a file may require access to several 958 * attributes and so in some implementations this method may not be atomic 959 * with respect to other file system operations. |