31 * systems. The API to access file and file system attributes is defined in the |
31 * systems. The API to access file and file system attributes is defined in the |
32 * {@link java.nio.file.attribute} package. The {@link java.nio.file.spi} |
32 * {@link java.nio.file.attribute} package. The {@link java.nio.file.spi} |
33 * package is used by service provider implementors wishing to extend the |
33 * package is used by service provider implementors wishing to extend the |
34 * platform default provider, or to construct other provider implementations. </p> |
34 * platform default provider, or to construct other provider implementations. </p> |
35 * |
35 * |
36 * <a name="links"><h3>Symbolic Links</h3></a> |
36 * <h3><a name="links">Symbolic Links</a></h3> |
37 * Many operating systems and file systems support for <em>symbolic links</em>. |
37 * <p> Many operating systems and file systems support for <em>symbolic links</em>. |
38 * A symbolic link is a special file that serves as a reference to another file. |
38 * A symbolic link is a special file that serves as a reference to another file. |
39 * For the most part, symbolic links are transparent to applications and |
39 * For the most part, symbolic links are transparent to applications and |
40 * operations on symbolic links are automatically redirected to the <em>target</em> |
40 * operations on symbolic links are automatically redirected to the <em>target</em> |
41 * of the link. Exceptions to this are when a symbolic link is deleted or |
41 * of the link. Exceptions to this are when a symbolic link is deleted or |
42 * renamed/moved in which case the link is deleted or removed rather than the |
42 * renamed/moved in which case the link is deleted or removed rather than the |
43 * target of the link. This package includes support for symbolic links where |
43 * target of the link. This package includes support for symbolic links where |
44 * implementations provide these semantics. File systems may support other types |
44 * implementations provide these semantics. File systems may support other types |
45 * that are semantically close but support for these other types of links is |
45 * that are semantically close but support for these other types of links is |
46 * not included in this package. </p> |
46 * not included in this package. </p> |
47 * |
47 * |
48 * <a name="interop"><h3>Interoperability</h3></a> |
48 * <h3><a name="interop">Interoperability</a></h3> |
49 * The {@link java.io.File} class defines the {@link java.io.File#toPath |
49 * <p> The {@link java.io.File} class defines the {@link java.io.File#toPath |
50 * toPath} method to construct a {@link java.nio.file.Path} by converting |
50 * toPath} method to construct a {@link java.nio.file.Path} by converting |
51 * the abstract path represented by the {@code java.io.File} object. The resulting |
51 * the abstract path represented by the {@code java.io.File} object. The resulting |
52 * {@code Path} can be used to operate on the same file as the {@code File} |
52 * {@code Path} can be used to operate on the same file as the {@code File} |
53 * object. The {@code Path} specification provides further information |
53 * object. The {@code Path} specification provides further information |
54 * on the <a href="Path.html#interop">interoperability</a> between {@code Path} |
54 * on the <a href="Path.html#interop">interoperability</a> between {@code Path} |
55 * and {@code java.io.File} objects. </p> |
55 * and {@code java.io.File} objects. </p> |
56 * |
56 * |
57 * <h3>Visibility</h3> |
57 * <h3>Visibility</h3> |
58 * The view of the files and file system provided by classes in this package are |
58 * <p> The view of the files and file system provided by classes in this package are |
59 * guaranteed to be consistent with other views provided by other instances in the |
59 * guaranteed to be consistent with other views provided by other instances in the |
60 * same Java virtual machine. The view may or may not, however, be consistent with |
60 * same Java virtual machine. The view may or may not, however, be consistent with |
61 * the view of the file system as seen by other concurrently running programs due |
61 * the view of the file system as seen by other concurrently running programs due |
62 * to caching performed by the underlying operating system and delays induced by |
62 * to caching performed by the underlying operating system and delays induced by |
63 * network-filesystem protocols. This is true regardless of the language in which |
63 * network-filesystem protocols. This is true regardless of the language in which |
64 * these other programs are written, and whether they are running on the same machine |
64 * these other programs are written, and whether they are running on the same machine |
65 * or on some other machine. The exact nature of any such inconsistencies are |
65 * or on some other machine. The exact nature of any such inconsistencies are |
66 * system-dependent and are therefore unspecified. </p> |
66 * system-dependent and are therefore unspecified. </p> |
67 * |
67 * |
68 * <a name="integrity"><h3>Synchronized I/O File Integrity</h3></a> |
68 * <h3><a name="integrity">Synchronized I/O File Integrity</a></h3> |
69 * The {@link java.nio.file.StandardOpenOption#SYNC SYNC} and {@link |
69 * <p> The {@link java.nio.file.StandardOpenOption#SYNC SYNC} and {@link |
70 * java.nio.file.StandardOpenOption#DSYNC DSYNC} options are used when opening a file |
70 * java.nio.file.StandardOpenOption#DSYNC DSYNC} options are used when opening a file |
71 * to require that updates to the file are written synchronously to the underlying |
71 * to require that updates to the file are written synchronously to the underlying |
72 * storage device. In the case of the default provider, and the file resides on |
72 * storage device. In the case of the default provider, and the file resides on |
73 * a local storage device, and the {@link java.nio.channels.SeekableByteChannel |
73 * a local storage device, and the {@link java.nio.channels.SeekableByteChannel |
74 * seekable} channel is connected to a file that was opened with one of these |
74 * seekable} channel is connected to a file that was opened with one of these |
81 * is made. Whether this guarantee is possible with other {@link |
81 * is made. Whether this guarantee is possible with other {@link |
82 * java.nio.file.spi.FileSystemProvider provider} implementations is provider |
82 * java.nio.file.spi.FileSystemProvider provider} implementations is provider |
83 * specific. </p> |
83 * specific. </p> |
84 * |
84 * |
85 * <h3>General Exceptions</h3> |
85 * <h3>General Exceptions</h3> |
86 * Unless otherwise noted, passing a {@code null} argument to a constructor |
86 * <p> Unless otherwise noted, passing a {@code null} argument to a constructor |
87 * or method of any class or interface in this package will cause a {@link |
87 * or method of any class or interface in this package will cause a {@link |
88 * java.lang.NullPointerException NullPointerException} to be thrown. Additionally, |
88 * java.lang.NullPointerException NullPointerException} to be thrown. Additionally, |
89 * invoking a method with a collection containing a {@code null} element will |
89 * invoking a method with a collection containing a {@code null} element will |
90 * cause a {@code NullPointerException}, unless otherwise specified. </p> |
90 * cause a {@code NullPointerException}, unless otherwise specified. </p> |
91 * |
91 * |