EGL Development User Group

EGL Development User Group

EGL Development User Group

The EGL Development User Group is dedicated to sharing news, knowledge, and insights regarding the EGL language and Business Developer product. Consisting of IBMers, HCL, and users, this community collaborates to advance the EGL ecosystem.

 View Only

Importing and Exporting a Project in RBD v8.0.1

By Jiyong Huang posted Wed April 01, 2020 09:18 PM

  
Starting in Rational Business Developer version 8.0.1, the Project Interchange Format (PIF) import/export wizard has been replaced by existing Eclipse Import and Export wizards. You can use these wizards to export EGL projects to an archive file and import EGL projects from an existing PIF or archive file.

To export an EGL project, use the Export Archive File wizard as follows:
  • Right click on the project and select Export > General > Archive File
  • Click Next.
  • Select or enter the full path to the destination .zip file
  • Click Finish.
image


In this example, myProject is exported to d:\temp\myProject.zip.

To import an EGL project into your workspace from an existing PIF or archive file, do the following:
  • Click File > Import > General > Existing Projects into Workspace
  • Click Next.
  • Click Select archive file, and browse to the location of the zip file.
  • Select the project(s) you want to import.
  • Click Finish.
image
In this example, myProject in d:\temp\myProject.zip is imported into your workspace.


Managing Empty Java Source Folders


EGL projects can contain two types of Java source folders. 

  • The EGLGen/JavaSource folder contains EGL-generated Java code.  This folder is empty until EGL parts are manually or automatically generated.  Cleaning a project causes the contents of this folder to be regenerated. 
  • A root JavaSource or src folder contains hand-modifiedJava code that you do not want replaced when a project is cleaned. This folder is empty until you populate it.  This separation was doneto make it easier for youto maintain hand-coded Java code within your EGL project.

Due to an existing Eclipse bug (Bugzilla #278402 - [Import/Export] Export project does not export empty folders), empty folders in a project are not exported.  If a Java source folder in an EGL project is empty (i.e. not exported), the following errors will occur when someone imports the project:

image
These problems occur because a Java source folder in the Java build path doesn't exist in the project.  (To check a project's Java build path, right click on the project and select Properties > Java Build Path.  Click the Source tab to see the source folders.)

The Eclipse bug is being worked on, but until it is fixed, you can either 1) remove or 2) populate empty source folders on the project's Java build path before exporting an EGL project:

  • To remove an empty source folder:
    1. In the Java Build Path properties page, select the source folder.
    2. Click Remove.
If you remove EGLGen/JavaSource but it is later needed to hold generated Java, RBD will create a new one.

  • To create a file in an empty source folder:
    1. Right click on the folder in the Project Explorer and select New > Other > General > File.
    2. Click Next.
    3. Enter a file name (e.g. dummy.txt).
    4. Click Finish.
    5. Close the file.  It can be empty.
This will cause the folder to be exported, thus preventing errors after import.

After importing a project with errors, you can either 1) remove the missing source folder from the project’s Java build path or 2) create the folder in the project:

  • To use Quick Fix to remove the folder from the Java build path:
    1. In the Problems view, right click on a build path problem and select Quick Fix.
    2. Click Finish on in the Quick Fix wizard to bring up the project’s Java Build Path properties page.
    3. Remove the “missing” folders.
    4. Click OK.

  • To create the missing Java source folder in the project:
  1. Right click on the project in the Project Explorer and select New > Folder
  2. Create a file (e.g. dummy.txt) in the new folder as explained above.  The file itself can be empty.  This will allow the folder to be exported with the rest of the project.

If you prefer, you can change your Java preferences to treat Java build path problems as warnings instead of errors.  To do this:

  1. Click Window > Preferences > Java > Compiler > Building.
  2. Change the value of the Incomplete build path field from Error to Warning.
  3. Click OK.
  4. Click Yes when asked if you want a full rebuild.

image
Alice
0 comments
0 views

Permalink