Uploaded image for project: 'Pivot'
  1. Pivot
  2. PIVOT-576

allow the key for an object that will be placed into a dictionary to specified bxml:key or use the bxml:id if one is specified.

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Won't Fix
    • None
    • None
    • core-beans
    • None

    Description

      When adding data to the user data (or any dictionary) it would help declutter BXML code and reduce duplication if the key for the dictionary entry could be specified directly on the object.

      Proposal:

      a) Use bxml:key as the attribute that specifies the key.
      b) Use bxml:id if a key is not specified.

      Example:

      Instead of this:
      <aDictLikeUserData>
      <myKey>
      <MyObject ... />
      </myKey>
      <aDictLikeUserData>

      you can use:

      <aDictLikeUserData>
      <MyObject bxml:key="myKey" .../>
      </aDictLikeUserData>

      or as a backup if key is not defined by id is:

      <aDictLikeUserData>
      <MyObject bxml:id="myKeyAndId" ... />
      </aDictLikeUserData>

      I have a BXMLSerializer patch. It's about a dozen lines including braces.

      Attachments

        Activity

          People

            Unassigned Unassigned
            aappddeevv Appddevvv
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: