Uploaded image for project: 'HiveMind'
  1. HiveMind
  2. HIVEMIND-100

unique attribute does not distinguish between values that are translated

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.1
    • 1.1
    • framework
    • None
    • J2SDK 1.4.2_04 on W2000

    Description

      Given an schema defining an attribute as unique and being translated
      by the translator 'qualified-id'.

      Given two modules contributing an element with same local
      value for the unique attribute.

      This causes an ApplicationRuntimeException at

      org.apache.hivemind.impl.SchemaElement#validateAttributes
      {
      ...
      throw new ApplicationRuntimeException(buffer.toString(), element.getLocation(), null);
      }

      with message:
      Value for attribute ''

      {0}

      '' (''

      {1}

      '') duplicates a prior instance at

      {2}

      .

      Expected behaviour:
      No complaint about duplicate values because the translated values are not equal.

      Solution:
      translate values before checking uniqueness. Patch follows.

      Attachments

        1. unique-attribute.patch
          14 kB
          Michael Frericks

        Activity

          People

            Unassigned Unassigned
            frericksm2 Michael Frericks
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: