Uploaded image for project: 'Tuscany'
  1. Tuscany
  2. TUSCANY-1395

XSD2JavaGenerator -noUnsettable option is broken for models with xsd:int or xsd:boolean types

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Duplicate
    • Java-SDO-Next
    • Java-SDO-1.0
    • Java SDO Tools
    • None
    • Patch Available

    Description

      Classes generated by XSD2JavaGenerator with the -noUnsettable option do not compile if the associated schema has elements/attributes of type xsd:int or xsd:boolean.

      In order to reproduce the problem, invoke XSD2JavaGenerator with the -noUnsettable flag and the customerAccount.xsd test schema. The following method in the generated com.example.customer.impl.AccountImpl class has a compiler error in its last line [notify(int, int, int, int) is invalid].

      public void setAccountNum(int newAccountNum)

      { int oldAccountNum = accountNum; accountNum = newAccountNum; if (isNotifying()) notify(ChangeKind.SET, ACCOUNT_NUM, oldAccountNum, accountNum); // COMPILER ERROR }
      • Ron

      Attachments

        Activity

          People

            Unassigned Unassigned
            rgavlin Ron Gavlin
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: