Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6985565

io - wrong ex name

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: P4 P4
    • None
    • 6-pool
    • docs
    • generic
    • generic

      Please be aware that there is mistake in this page:

      http://download.oracle.com/javase/tutorial/essential/io/file.html

      In this code:

      Path file = ...;
      try {
          file.createFile(); //Create the empty file with default permissions, etc.
      } catch (FileAlreadyExists x) {
          System.err.format("file named %s already exists%n", file);
      } catch (IOException x) {
          //Some other sort of failure, such as permissions.
          System.err.format("createFile error: %s%n", x);
      }

      There is no exception by the name "FileAlreadyExists"

            Unassigned Unassigned
            skannan Sowmya Kannan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: