6867781: (file) Examples in javadoc use newFileAttributeView instead of getFileAttributeView
authoralanb
Tue, 11 Aug 2009 12:38:43 +0100
changeset 3487 e0d89f22e6ef
parent 3486 0e14ae32369e
child 3488 852e79d01c34
6867781: (file) Examples in javadoc use newFileAttributeView instead of getFileAttributeView Reviewed-by: sherman
jdk/src/share/classes/java/nio/file/attribute/AclFileAttributeView.java
jdk/src/share/classes/java/nio/file/attribute/PosixFileAttributeView.java
--- a/jdk/src/share/classes/java/nio/file/attribute/AclFileAttributeView.java	Tue Aug 11 12:37:02 2009 +0100
+++ b/jdk/src/share/classes/java/nio/file/attribute/AclFileAttributeView.java	Tue Aug 11 12:38:43 2009 +0100
@@ -75,7 +75,7 @@
  *         .lookupPrincipalByName("joe");
  *
  *     // get view
- *     AclFileAttributeView view = file.newFileAttributeView(AclFileAttributeView.class);
+ *     AclFileAttributeView view = file.getFileAttributeView(AclFileAttributeView.class);
  *
  *     // create ACE to give "joe" read access
  *     AclEntry entry = AclEntry.newBuilder()
--- a/jdk/src/share/classes/java/nio/file/attribute/PosixFileAttributeView.java	Tue Aug 11 12:37:02 2009 +0100
+++ b/jdk/src/share/classes/java/nio/file/attribute/PosixFileAttributeView.java	Tue Aug 11 12:38:43 2009 +0100
@@ -61,7 +61,7 @@
  * Suppose we need to print out the owner and access permissions of a file:
  * <pre>
  *     FileRef file = ...
- *     PosixFileAttributes attrs = file.newFileAttributeView(PosixFileAttributeView.class)
+ *     PosixFileAttributes attrs = file.getFileAttributeView(PosixFileAttributeView.class)
  *         .readAttributes();
  *     System.out.format("%s %s%n",
  *         attrs.owner().getName(),