Java API Package Worksheet
Introduction
A Java API Package Worksheet describes how AlchemyJ Compiler should generate a package. It defines the name of the package, the classes it contains and properties for the unit test project.
It contains the following sections:
Basic Settings
Define the basic information of a Java Package.
Item | Description |
---|---|
Package Name | Define the name of this Java Package. For example com.company.myfirstjavaproject. |
Jar name | If you want to generate a Jar file (Source Type is Jar). Define it here. |
Version | Version number of this Java Project. The user of this API may use the version number to specify which version of the API to import from a Maven Repository. |
Classes
It defines the Class Definition Sheet(s) name included in this Java Package.
Unit Test Settings
This section defines the unit test database information and external resource path.
Refer to Testing Tool for test steps.
Properties | Description |
---|---|
Database | These are 3 types of the database that you can select from: MsSql Oracle MSSQL |
Data source JDBC URL | JDBC URL for the JDBC connection used in the unit test project. Oracle: MySQL: MSSQL: |
Data source user name | User name of the database connection |
Data source password | Password of the database user |
Resource path | Path of unit test resource files. This folder path specifies where unit test data files should be loaded. |
Resource date format | The date format for date conversion. Default is yyyy-MM-dd HH:mm:ss |
Maven Dependency
If your model use ajCallFunction to call other Java packages, you should define them in Maven Dependency section. When AlchemyJ generates the API, it will include the related packages into the project. Each row in the table refers to one package.
Item | Description |
---|---|
Maven Group ID | Define a Group ID for the dependent package. It should follow Java's package name rules. You can use the same value as the package name. |
Maven Artifact ID | Define a unique Artifact ID for the depended project. The Group ID and Artifact ID together should uniquely identify this project across all projects. |
Maven Version | Version number of the dependent Java Project. The user of this API can use the version number to specify which version of the API to import from a Maven Repository. |
Scope | compile - The dependency is required for compilation and execution. runtime - The dependency is not required for compilation but required for execution. provided - The dependency will be provided by the application server. Default is compile. |
Advance Settings
Item | Description |
---|---|
Maven Group ID | Define a Group ID for this package. It should follow Java's package name rules. You can use the same value as the package name. |
Maven Artifact ID | Define a unique Artifact ID for this project. The Group ID and Artifact ID together should uniquely identify this project across all projects. |