Code regeneration, refactoring, and clean up

After changing your business type schema files, you can use the regeneration utility to generate the affected Java™ binding bean files. If the changes to the business type schema files render any Java binding bean files unnecessary, you can use the clean-up utility to remove these obsolete files.

Procedure

  1. Code regeneration: After changing your business type schema files, you can use the regeneration utility to generate the affected Java binding bean files. Right-click the file that you have changed and select Generate > J2C Java data binding.
    • Top pane: The top pane displays the XSD files that is used for regeneration, and the one you have modified appears in bold.
    • Bottom pane: The bottom pane displays the Java data binding beans that are generated.
  2. Code refactoring: If you change only to the type name in your business type schema files, the recommended way is to cascade these changes to the affected Java data binding files. Open the business type schema file in the XSD editor, select Design view. On the Typespanel, right-click your type name, select Refactor > Rename. Your business type schema file is updated with the new name.
    Refactor dialog
  3. Code clean up: After changing your business type schema files, some Java binding files might be rendered unnecessary. Right-click on the project that you want to clean up. Select Source > Clean up obsolete J2C Java data bindings. On the Clean-up page, select OK to remove these files and Cancel to retain these files in your workspace.

Feedback