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

Add a way to convert a CompositeData into a Map

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b41
    • CPU:
      generic
    • OS:
      generic
    • Verification:
      Verified

      Description

      CompositeDataSupport has a constructor that takes a CompositeType and a Map<String,?>. But it doesn't have the reverse option, to produce a Map<String, Object> that contains the items from the CompositeData. This would be very useful to support the creation of another CompositeData that is the same as the first except for one or two items. For example:

      CompositeData cd = ...whatever...;
      Map<String, Object> map = CompositeDataSupport.toMap(cd);
      map.put("foo", "bar");
      cd = new CompositeDataSupport(cd.getCompositeType(), map);

        Attachments

          Activity

            People

            Assignee:
            emcmanus Eamonn McManus
            Reporter:
            emcmanus Eamonn McManus
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: