Uploaded image for project: 'XMLBeans'
  1. XMLBeans
  2. XMLBEANS-396

GML 3.1.1 generated code fails to compile.

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: Version 2.4.1
    • Fix Version/s: Version 2.5.1
    • Component/s: None
    • Labels:
      None

      Description

      After generating code for GML 3.1.1, the code fails to compile. The following compilation error is given:
      generatedSetterHelperImpl(org.apache.xmlbeans.XmlObject,javax.xml.namespace.QName,int,short) in org.apache.xmlbeans.impl.values.XmlObjectBase cannot be applied to (java.lang.Object,javax.xml.namespace.QName,int,short) generatedSetterHelperImpl(xnull, NULL$26, i, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_ARRAYITEM);

      It appears this error is a result of changes made to SchemaTypeCodePrinter.java. The call generatedSetterHelperImpl is called in 2 places in this class, however the second place is surrounded by an "if ( isobj )" which appears to generate invalid code. I believe this code needs to be updated to reflect the "if ( xmltype && !isSubstGroup )" as in the first place the code is called.

      This code change fixed the issue with GML 3.1.1 gode generation. Someone more familiar with the code should verify and commit this change.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              sirhc1984 Chris Clark
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: