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

Doc for java.net.URLStreamHandler is silent about the protocol name changing

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P4
    • Resolution: Duplicate
    • Affects Version/s: 1.3.0
    • Fix Version/s: None
    • Component/s: docs
    • Subcomponent:
    • CPU:
      sparc
    • OS:
      solaris_2.6

      Description



      Name: dfC67450 Date: 09/03/99




      The method setURL(URL, String, String, int, String, String, String, String, String)
      of URLStreamHandler does not allow to change the protocol name.
      Its source:


          protected void setURL(URL u, String protocol, String host, int port,
      String authority, String userInfo, String path,
                                   String query, String ref) {
      if (this != u.handler) {
      throw new SecurityException("handler for url different from " +
      "this handler");
      }
      // ensure that no one can reset the protocol on a given URL.
              u.set(u.getProtocol(), host, port, authority, userInfo, path, query, ref);
          }

      But doc for both URLStreamHandler and URL is silent about this feature.

      ======================================================================

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                shommel Scott Hommel (Inactive)
                Reporter:
                fdasunw Fda Fda (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: