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

(file) Paths.get(String) and Path.resolve(String) should support varargs

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Duplicate
    • P3
    • None
    • 7
    • core-libs
    • None
    • generic
    • generic

    Description

      Where a path is created from a sequence of names it requires code like following:
        Path file = dir.resolve("images" + fs + "foo.png");
      or
        Path file = dir.resolve("images").resolve("folder.png");

      It has been suggested that FileSystem.getPath(String), and Path.resolve(String) be extended to use varargs so as to support usages such as the following:
        Path file = dir.resolve("images", "folder.png");

      Attachments

        Issue Links

          Activity

            People

              alanb Alan Bateman
              alanb Alan Bateman
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: