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

Remove MulticastSocket methods that operate on java.net.InetAddress

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Open
    • Priority: P3
    • Resolution: Unresolved
    • Affects Version/s: 14
    • Fix Version/s: None
    • Component/s: core-libs
    • Labels:
      None

      Description

      There are a number of methods in MulticastSocket that operate on a
      java.net.InetAddress. These methods have been superseded, in Java 1.4,
      by equivalents that operate on a java.net.NetworkInterface ( which
      itself was added in java 1.4). Operating on the network interface is
      more reliable than an InetAddress, and therefore these newer methods are
      the preferred way to interact with MulticsatSocket. The older methods
      should be deprecated, with a view to eventual removal.

      Remove:
        void setInterface(InetAddress)
        InetAddress getInterface()
        void joinGroup(InetAddress)
        void leaveGroup(InetAddress)
        
      Effective replacements are:
        void setNetworkInterface(NetworkInterface)
        NetworkInterface getNetworkInterface()
        joinGroup(SocketAddress, NetworkInterface)
        void leaveGroup(SocketAddress, NetworkInterface)

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            chegar Chris Hegarty
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: