This is a feature of JBuilder Professional and Enterprise.
To open the Data Module wizard, choose File|New to open the Object Gallery. Double-click the Data Module icon.
Data modules simplify data access development in your applications. Data modules offer you a centralized container for all your data access components. This enables you to modularize your code and separate the database access logic and business rules in your applications from the visual containers like panels and frames.
The Data Module wizard creates a data module, or specialized container for data access components. Once you define your DataSet components and their corresponding Column components in a data module, all frames that use the module have consistent access to the data sets and columns without requiring you to recreate them on every frame each time you need them. Data modules do not need to reside in the same directory or package as your project. They can be stored in a location for shared use among developers and applications. For more information on data modules, including a tutorial, see "Using data modules to simplify data access" in the Database Application Developer's Guide.
If a project is currently open, the Data Module wizard displays. If no project is currently open, the Project wizard steps you through creating a new project. Then, the Data Module wizard is displayed.
This field displays the package name derived from the project file. To assign a different package name to the data module file, click in the Package field and type in a new name.
For more information on packages, see the "Packages" topic in the "Creating and managing projects" in Building Applications with JBuilder..
This field displays the default name assigned to the data module class. To rename it, click in the Class Name field and type in a new name.
When this option is checked, and OK is clicked, the Data Modeler displays. The Data Modeler assists you in defining one or more SQL queries that connect to JDBC databases. It can also help you define master-detail relationships between queries. After you build your SQL queries, you can store the result as a JBuilder data module in a .java file.
See "Creating database applications using the Data Modeler" for information about building SQL queries using the Data Modeler.
For more information on data modules and the Data Modeler, see "Creating data modules using the Data Modeler" in the Database Application Developer's Guide.
Uses information from the project file as header comments at the top of the data module class file. This is the information you entered in the Project wizard when creating the project file.
/** * Title: Your product name * Description: Your description * Copyright: Copyright (c) 2001 * Company: Your company * @author Your name * @version 1.0 */
If Invoke Data Modeler is selected, the Data Modeler displays when you select OK. Refer to the Data Modeler online help for more information on using the Data Modeler.
If Invoke Data Modeler is not selected, when you select OK, the wizard creates your custom data module. You can add Data Access components to the data module in the UI Designer. Adding Data Access components through the UI Designer also generates getter methods for these components.
To use a data module, it must be compiled. To use a compiled data module in the current project, run wizards|Use Data Module. To use a compiled data module from another project, make sure to add the data module class to the Required Libraries in Project|Project Properties.