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

incomplete spec for java.net.DatagramPacket constructors

XMLWordPrintable

    • generic
    • generic

      According to the bug 4662789 SocketException could not be thrown in any
      condition but descriptions of two DatagramPacket contructors still have
      SocketException in "Throws" paragraph.

      For the following constructors:
      public DatagramPacket(byte[] buf, int length, SocketAddress address)
      public DatagramPacket(byte[] buf, int offset, int length, SocketAddress address)

      the spec in "Throws" paragraph says:
      " Throws:
             IllegalArgumentException - if address type is not supported
             SocketException"

      So, the spec. shouldn't mention SocketException for these constructors.

      ###@###.### 2004-03-26

            yuwangsunw Yujiang Wang (Inactive)
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: