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

ObjectName.withDomain should throw IAE instead of MalformedObjectNameException

    • Icon: Enhancement Enhancement
    • Resolution: Not an Issue
    • Icon: P4 P4
    • tbd
    • 7
    • core-svc

      In JDK 7 ObjectName has acquired a set of static valueOf(...) methods which
      throw IAE instead of the traditional checked MalformedObjectNameException.
      This is very practical when you need to initialize a static variable of type
      ObjectName - or when creating an ObjectName in a constructor, etc..
      withDomain is also new in JDK 7, and could legitimately be used in static
      initializers and constructors too - so it would make sense to make it
      throw IAE instead of MalformedObjectNameException too.

            dfuchs Daniel Fuchs
            dfuchs Daniel Fuchs
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: