Eclipse Configuration
In order to run the programming parts of this tutorial under Eclipse you need to setup a Java project. We recommend to use "Eclipse for Java Developers".
An explanation on how to set up a Java project can be found here.
- Call your project "AnBxTutorial" (step 2).
- For this tutorial you need to add a reference to the AnBxJ library (step
8).
Right click on the root folder of your project, select "Properties". Then select "Java Build Path" -> "Libraries"
If a reference to AnBxJ.jar is not present, select "Add External JARs ..." and select the location of your AnBxJ.jar file. - Be aware that source files must be added under the src folder. In the same folder you could expand also the keystore file.
- In order to run the client and the server you need to setup a "Run
configuration" under "Java Applications"
Select "Run" -> "Run configurations..."
Create a new configuration. If your application is "Tutorial_01.java" set the following parameters:
Main
Project: "Tutorial_01 (server)"
Main Class: "Tutorial_01"
Arguments
Program arguments: "server"
Working directory: "${workspace_loc:AnBxTutorial}"\src
Click on "Apply" and "Run"
Repeat the same for the "client"
Remarks:
- The working directory must be set to "src" in order to allow the program to find the right path of the keystore folder (which is subfolder of src).
- The executable files (.class) are created in the folder bin
The configuration of the AnBx-IDE (eclipse plug in) is available
here.