Lines Matching refs:link

72      * will not be buffered, and is not required to support the {@link
73 * InputStream#mark mark} or {@link InputStream#reset reset} methods. The
81 * the {@link StandardOpenOption#READ READ} option. In addition to the {@code
100 * installed, the {@link SecurityManager#checkRead(String) checkRead}
118 * by the {@link #newByteChannel(Path,Set,FileAttribute[]) newByteChannel}
119 * method with the exception that the {@link StandardOpenOption#READ READ}
121 * present then this method works as if the {@link StandardOpenOption#CREATE
122 * CREATE}, {@link StandardOpenOption#TRUNCATE_EXISTING TRUNCATE_EXISTING},
123 * and {@link StandardOpenOption#WRITE WRITE} options are present. In other
125 * exist, or initially truncating an existing {@link #isRegularFile
161 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
162 * method is invoked to check write access to the file. The {@link
178 * The {@link StandardOpenOption#READ READ} and {@link
180 * opened for reading and/or writing. If neither option (or the {@link
191 * <td> {@link StandardOpenOption#APPEND APPEND} </td>
201 * <td> {@link StandardOpenOption#TRUNCATE_EXISTING TRUNCATE_EXISTING} </td>
207 * <td> {@link StandardOpenOption#CREATE_NEW CREATE_NEW} </td>
209 * the file already exists or is a symbolic link. When creating a file the
215 * <td > {@link StandardOpenOption#CREATE CREATE} </td>
222 * <td > {@link StandardOpenOption#DELETE_ON_CLOSE DELETE_ON_CLOSE} </td>
225 * {@link SeekableByteChannel#close close} method. If the {@code close}
230 * <td>{@link StandardOpenOption#SPARSE SPARSE} </td>
236 * <td> {@link StandardOpenOption#SYNC SYNC} </td>
243 * <td> {@link StandardOpenOption#DSYNC DSYNC} </td>
254 * <p> The {@code attrs} parameter is optional {@link FileAttribute
258 * is a {@link java.nio.channels.FileChannel}.
292 * if a file of that name already exists and the {@link
299 * installed, the {@link SecurityManager#checkRead(String) checkRead}
301 * opened for reading. The {@link SecurityManager#checkWrite(String)
303 * if the file is opened for writing. The {@link
323 * by the {@link #newByteChannel(Path,Set,FileAttribute[]) newByteChannel}
338 * if a file of that name already exists and the {@link
345 * installed, the {@link SecurityManager#checkRead(String) checkRead}
347 * opened for reading. The {@link SecurityManager#checkWrite(String)
349 * if the file is opened for writing. The {@link
378 * Opens a directory, returning a {@link DirectoryStream} to iterate over
380 * stream's {@link DirectoryStream#iterator iterator} are of type {@code
382 * objects are obtained as if by {@link Path#resolve(Path) resolving} the
391 * stream is a {@link SecureDirectoryStream}.
405 * installed, the {@link SecurityManager#checkRead(String) checkRead}
415 * Opens a directory, returning a {@link DirectoryStream} to iterate over
417 * stream's {@link DirectoryStream#iterator iterator} are of type {@code
419 * objects are obtained as if by {@link Path#resolve(Path) resolving} the
433 * <p> The globbing pattern is specified by the {@link
442 * stream is a {@link SecureDirectoryStream}.
460 * installed, the {@link SecurityManager#checkRead(String) checkRead}
483 * Opens a directory, returning a {@link DirectoryStream} to iterate over
485 * stream's {@link DirectoryStream#iterator iterator} are of type {@code
487 * objects are obtained as if by {@link Path#resolve(Path) resolving} the
489 * the iterator are filtered by the given {@link DirectoryStream.Filter
497 * exception then it is propagated to the {@link Iterator#hasNext()
498 * hasNext} or {@link Iterator#next() next} method. Where an {@code
500 * next} method throwing a {@link DirectoryIteratorException} with the
505 * stream is a {@link SecureDirectoryStream}.
536 * installed, the {@link SecurityManager#checkRead(String) checkRead}
554 * <p> The {@code attrs} parameter is optional {@link FileAttribute
556 * is identified by its {@link FileAttribute#name name}. If more than one
578 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
594 * affect the directory. The {@link #createDirectories createDirectories}
598 * <p> The {@code attrs} parameter is optional {@link FileAttribute
600 * attribute is identified by its {@link FileAttribute#name name}. If more
622 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
634 * Unlike the {@link #createDirectory createDirectory} method, an exception
638 * <p> The {@code attrs} parameter is optional {@link FileAttribute
640 * directories. Each file attribute is identified by its {@link
666 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
668 * its {@link SecurityManager#checkRead(String) checkRead} is
670 * dir} is not an absolute path then its {@link Path#toAbsolutePath
672 * This may invoke the security manager's {@link
748 * names in the same manner as the {@link
753 * the resulting file may be opened using the {@link
756 * Alternatively, a {@link Runtime#addShutdownHook shutdown-hook}, or the
757 * {@link java.io.File#deleteOnExit} mechanism may be used to delete the
760 * <p> The {@code attrs} parameter is optional {@link FileAttribute
762 * is identified by its {@link FileAttribute#name name}. If more than one
766 * created by the {@link java.io.File#createTempFile(String,String,File)}
794 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
813 * {@link #createTempFile(Path,String,String,FileAttribute[])} method for
840 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
861 * part of a temporary-file facility. A {@link Runtime#addShutdownHook
862 * shutdown-hook}, or the {@link java.io.File#deleteOnExit} mechanism may be
865 * <p> The {@code attrs} parameter is optional {@link FileAttribute
867 * attribute is identified by its {@link FileAttribute#name name}. If more
892 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
910 * <p> This method works in exactly the manner specified by {@link
934 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
946 * Creates a symbolic link to a target <i>(optional operation)</i>.
948 * <p> The {@code target} parameter is the target of the link. It may be an
949 * {@link Path#isAbsolute absolute} or relative path and may not exist. When
951 * link are relative to the path of the link.
953 * <p> The {@code attrs} parameter is optional {@link FileAttribute
954 * attributes} to set atomically when creating the link. Each attribute is
955 * identified by its {@link FileAttribute#name name}. If more than one attribute
959 * <p> Where symbolic links are supported, but the underlying {@link FileStore}
960 * does not support symbolic links, then this may fail with an {@link
965 * @param link
966 * the path of the symbolic link to create
968 * the target of the symbolic link
971 * symbolic link
973 * @return the path to the symbolic link
978 * creating the symbolic link
986 * is installed, it denies {@link LinkPermission}<tt>("symbolic")</tt>
987 * or its {@link SecurityManager#checkWrite(String) checkWrite}
988 * method denies write access to the path of the symbolic link.
990 public static Path createSymbolicLink(Path link, Path target,
994 provider(link).createSymbolicLink(link, target, attrs);
995 return link;
999 * Creates a new link (directory entry) for an existing file <i>(optional
1002 * <p> The {@code link} parameter locates the directory entry to create.
1005 * accessed using {@code link} as the path. On some file systems this is
1006 * known as creating a "hard link". Whether the file attributes are
1014 * @param link
1015 * the link (directory entry) to create
1019 * @return the path to the link (directory entry)
1031 * is installed, it denies {@link LinkPermission}<tt>("hard")</tt>
1032 * or its {@link SecurityManager#checkWrite(String) checkWrite}
1033 * method denies write access to either the link or the
1036 public static Path createLink(Path link, Path existing) throws IOException {
1037 provider(link).createLink(link, existing);
1038 return link;
1046 * to other file system operations. If the file is a symbolic link then the
1047 * symbolic link itself, not the final target of the link, is deleted.
1053 * This method can be used with the {@link #walkFileTree walkFileTree}
1073 * installed, the {@link SecurityManager#checkDelete(String)} method
1083 * <p> As with the {@link #delete(Path) delete(Path)} method, an
1086 * other file system operations. If the file is a symbolic link, then the
1087 * symbolic link itself, not the final target of the link, is deleted.
1112 * installed, the {@link SecurityManager#checkDelete(String)} method
1126 * copy fails if the target file already exists or is a symbolic link,
1127 * except if the source and target are the {@link #isSameFile same} file, in
1130 * supported, and the file is a symbolic link, then the final target of the
1131 * link is copied. If the file is a directory then it creates an empty
1133 * copied). This method can be used with the {@link #walkFileTree
1142 * <td> {@link StandardCopyOption#REPLACE_EXISTING REPLACE_EXISTING} </td>
1145 * symbolic link, then the symbolic link itself, not the target of
1146 * the link, is replaced. </td>
1149 * <td> {@link StandardCopyOption#COPY_ATTRIBUTES COPY_ATTRIBUTES} </td>
1153 * {@link BasicFileAttributes#lastModifiedTime last-modified-time} is
1159 * <td> {@link LinkOption#NOFOLLOW_LINKS NOFOLLOW_LINKS} </td>
1160 * <td> Symbolic links are not followed. If the file is a symbolic link,
1161 * then the symbolic link itself, not the target of the link, is copied.
1163 * new link. In other words, the {@code COPY_ATTRIBUTES} option may be
1164 * ignored when copying a symbolic link. </td>
1171 * <p> Copying a file is not an atomic operation. If an {@link IOException}
1212 * installed, the {@link SecurityManager#checkRead(String) checkRead}
1214 * {@link SecurityManager#checkWrite(String) checkWrite} is invoked
1215 * to check write access to the target file. If a symbolic link is
1216 * copied the security manager is invoked to check {@link
1238 * target are the {@link #isSameFile same} file, in which case this method
1239 * has no effect. If the file is a symbolic link then the symbolic link
1240 * itself, not the target of the link, is moved. This method may be
1247 * directory on the same {@link FileStore} will usually not require moving
1251 * than moving directories and this can be done using the {@link
1252 * #copy copy} method in conjunction with the {@link
1260 * <td> {@link StandardCopyOption#REPLACE_EXISTING REPLACE_EXISTING} </td>
1263 * symbolic link, then the symbolic link itself, not the target of
1264 * the link, is replaced. </td>
1267 * <td> {@link StandardCopyOption#ATOMIC_MOVE ATOMIC_MOVE} </td>
1271 * fails by throwing an {@link IOException}. If the move cannot be
1272 * performed as an atomic file system operation then {@link
1282 * <p> Where the move requires that the file be copied then the {@link
1335 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
1356 * Reads the target of a symbolic link <i>(optional operation)</i>.
1359 * links</a> then this method is used to read the target of the link, failing
1360 * if the file is not a symbolic link. The target of the link need not exist.
1362 * system as {@code link}.
1364 * @param link
1365 * the path to the symbolic link
1367 * @return a {@code Path} object representing the target of the link
1373 * is not a symbolic link <i>(optional specific exception)</i>
1379 * granted with the "{@code readlink}" action to read the link.
1381 public static Path readSymbolicLink(Path link) throws IOException {
1382 return provider(link).readSymbolicLink(link);
1386 * Returns the {@link FileStore} representing the file store where a file
1391 * or {@link FileStoreAttributeView} objects obtained from it, continue
1405 * installed, the {@link SecurityManager#checkRead(String) checkRead}
1407 * addition it checks {@link RuntimePermission}<tt>
1417 * <p> If both {@code Path} objects are {@link Path#equals(Object) equal}
1448 * installed, the {@link SecurityManager#checkRead(String) checkRead}
1462 * isn't a directory and the DOS {@link DosFileAttributes#isHidden hidden}
1477 * installed, the {@link SecurityManager#checkRead(String) checkRead}
1519 * <p> This method uses the installed {@link FileTypeDetector} implementations
1521 * detector's {@link FileTypeDetector#probeContentType probeContentType} is
1529 * using the service-provider loading facility defined by the {@link ServiceLoader}
1587 * The {@link BasicFileAttributeView} type supports access to the basic
1593 * file is a symbolic link. By default, symbolic links are followed. If the
1594 * option {@link LinkOption#NOFOLLOW_LINKS NOFOLLOW_LINKS} is present then
1638 * are handled for the case that the file is a symbolic link. By default,
1640 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
1674 * installed, its {@link SecurityManager#checkRead(String) checkRead}
1698 * <p> <i>view-name</i> is the {@link FileAttributeView#name name} of a {@link
1706 * are handled for the case that the file is a symbolic link. By default,
1708 * of the link is set. If the option {@link LinkOption#NOFOLLOW_LINKS
1743 * installed, its {@link SecurityManager#checkWrite(String) checkWrite}
1767 * <p> <i>view-name</i> is the {@link FileAttributeView#name name} of a {@link
1774 * are handled for the case that the file is a symbolic link. By default,
1776 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
1804 * installed, its {@link SecurityManager#checkRead(String) checkRead}
1839 * <p> <i>view-name</i> is the {@link FileAttributeView#name name} of a {@link
1859 * <td> Read all {@link BasicFileAttributes basic-file-attributes}. </td>
1868 * <td> Read all {@link PosixFileAttributes POSIX-file-attributes}. </td>
1878 * are handled for the case that the file is a symbolic link. By default,
1880 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
1902 * installed, its {@link SecurityManager#checkRead(String) checkRead}
1918 * that supports the {@link PosixFileAttributeView}. This attribute view
1924 * are handled for the case that the file is a symbolic link. By default,
1926 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
1943 * installed, and it denies {@link RuntimePermission}<tt>("accessUserInformation")</tt>
1944 * or its {@link SecurityManager#checkRead(String) checkRead} method
1958 * that supports the {@link PosixFileAttributeView}. This attribute view
1978 * installed, it denies {@link RuntimePermission}<tt>("accessUserInformation")</tt>
1979 * or its {@link SecurityManager#checkWrite(String) checkWrite}
1998 * supports {@link FileOwnerAttributeView}. This file attribute view provides
2015 * installed, it denies {@link RuntimePermission}<tt>("accessUserInformation")</tt>
2016 * or its {@link SecurityManager#checkRead(String) checkRead} method
2031 * supports {@link FileOwnerAttributeView}. This file attribute view provides
2056 * installed, it denies {@link RuntimePermission}<tt>("accessUserInformation")</tt>
2057 * or its {@link SecurityManager#checkWrite(String) checkWrite}
2075 * Tests whether a file is a symbolic link.
2078 * that the file is not a symbolic link then the file attributes can be
2079 * read with the {@link #readAttributes(Path,Class,LinkOption[])
2080 * readAttributes} method and the file type tested with the {@link
2083 * @return {@code true} if the file is a symbolic link; {@code false} if
2084 * the file does not exist, is not a symbolic link, or it cannot
2085 * be determined if the file is a symbolic link or not.
2089 * installed, its {@link SecurityManager#checkRead(String) checkRead}
2106 * are handled for the case that the file is a symbolic link. By default,
2108 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
2113 * read with the {@link #readAttributes(Path,Class,LinkOption[])
2114 * readAttributes} method and the file type tested with the {@link
2128 * installed, its {@link SecurityManager#checkRead(String) checkRead}
2143 * are handled for the case that the file is a symbolic link. By default,
2145 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
2150 * read with the {@link #readAttributes(Path,Class,LinkOption[])
2151 * readAttributes} method and the file type tested with the {@link
2165 * installed, its {@link SecurityManager#checkRead(String) checkRead}
2180 * are handled for the case that the file is a symbolic link. By default,
2182 * of the link is read. If the option {@link LinkOption#NOFOLLOW_LINKS
2199 * installed, its {@link SecurityManager#checkRead(String) checkRead}
2237 * In the case of the default provider, the security manager's {@link
2254 * files, or other reasons. The size of files that are not {@link
2267 * installed, its {@link SecurityManager#checkRead(String) checkRead}
2299 * are handled for the case that the file is a symbolic link. By default,
2300 * symbolic links are followed. If the option {@link LinkOption#NOFOLLOW_LINKS
2317 * In the case of the default provider, the {@link
2347 * are handled for the case that the file is a symbolic link. By default,
2348 * symbolic links are followed. If the option {@link LinkOption#NOFOLLOW_LINKS
2351 * <p> Note that this method is not the complement of the {@link #exists
2368 * In the case of the default provider, the {@link
2427 * installed, the {@link SecurityManager#checkRead(String) checkRead}
2458 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
2467 * and that this Java virtual machine has appropriate privileges to {@link
2493 * installed, the {@link SecurityManager#checkExec(String)
2506 * file tree traversal is <em>depth-first</em> with the given {@link
2509 * visit method returns a result of {@link FileVisitResult#TERMINATE
2514 * <p> For each file encountered this method attempts to read its {@link
2516 * directory then the {@link FileVisitor#visitFile visitFile} method is
2518 * due to an I/O exception, then the {@link FileVisitor#visitFileFailed
2529 * directory, then the directory is closed and the visitor's {@link
2535 * method. If the {@code options} parameter contains the {@link
2539 * of the link. If they can be read then the {@code visitFile} method is
2540 * invoked with the attributes of the link (otherwise the {@code visitFileFailed}
2543 * <p> If the {@code options} parameter contains the {@link
2547 * directory. Cycle detection is done by recording the {@link
2549 * or if file keys are not available, by invoking the {@link #isSameFile
2552 * {@link FileVisitor#visitFileFailed visitFileFailed} method is invoked with
2553 * an instance of {@link FileSystemLoopException}.
2558 * {@link Integer#MAX_VALUE MAX_VALUE} may be used to indicate that all
2586 * In the case of the default provider, the {@link
2624 * In the case of the default provider, the {@link
2666 * installed, the {@link SecurityManager#checkRead(String) checkRead}
2683 * opened. If no options are present then this method works as if the {@link
2684 * StandardOpenOption#CREATE CREATE}, {@link
2685 * StandardOpenOption#TRUNCATE_EXISTING TRUNCATE_EXISTING}, and {@link
2688 * initially truncating an existing {@link #isRegularFile regular-file} to
2710 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
2745 * symbolic link. If the {@link StandardCopyOption#REPLACE_EXISTING
2748 * file exists and is a symbolic link, then the symbolic link is replaced.
2799 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
2802 * manager's {@link SecurityManager#checkDelete(String) checkDelete}
2871 * <p> Note that if the given output stream is {@link java.io.Flushable}
2872 * then its {@link java.io.Flushable#flush flush} method may need to invoked
2886 * installed, the {@link SecurityManager#checkRead(String) checkRead}
2953 * installed, the {@link SecurityManager#checkRead(String) checkRead}
3000 * installed, the {@link SecurityManager#checkRead(String) checkRead}
3023 * works as if the {@link StandardOpenOption#CREATE CREATE}, {@link
3024 * StandardOpenOption#TRUNCATE_EXISTING TRUNCATE_EXISTING}, and {@link
3027 * initially truncating an existing {@link #isRegularFile regular-file} to
3058 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}
3088 * {@link StandardOpenOption#CREATE CREATE}, {@link
3089 * StandardOpenOption#TRUNCATE_EXISTING TRUNCATE_EXISTING}, and {@link
3092 * initially truncating an existing {@link #isRegularFile regular-file} to
3116 * installed, the {@link SecurityManager#checkWrite(String) checkWrite}