11. After sharing projects in the resource library, you can use the "Synchronization" feature to "Synchronize" and caught up with someone else's modifications to the code in the resource library. Right-click on the project, group → synchronize with the repository.
Download, install application server JBoss
In order to do server-side development, you still need an application server and integrate the application server with Eclipse. Eclipse can work together with a variety of application servers, including WebLogic, WebSphere, Jrun, Orion / Oracle9ias, JBoss, Jonas, Resin, etc. The following is exemplified by the current popular open source application server JBoss. The first thing I want to download and install JBoss, I am using JBoss 3.0.3, installed in the D: /JBoss-3.0.3 directory. In order to integrate JBoss with Eclipse, you also need to download related plugins, download location is http://www.genuitec.com/products_easie.htm, http://www.genuitec.com/products/easiejboss1.0.6.zip. There is also a installation guide in http://www.genuitec.com/products/eclipse_jboss.pdf. Exit Eclipse, unzip the file just downloaded under D: / Eclipse, restart Eclipse. The newly installed plugin needs to be activated to use, select window → custom perspective, select the EASIE JBOSS item in "Other". Then configure this plugin, select Window → Preferences, and enter information about JBOSS plug-ins. After the above is performed, the button that starts and stops JBoss will appear in the toolbar. Click the Start button to start JBoss, as shown in Figure 6.
Figure 6 Start JBoss
Open the debugging view, you will see the JBoss process related to the initiated JBoss process in the debug perspective. Stop JBoss can use the stop button next to the start button. On this website, there is also a plugin for WebLogic, WebSphere, Orion / Oracle 9ias, and the installation method is basically exactly the same.
Eclipse debugging
So far, the configuration required to establish a complete development environment is basically completed. Let's go back to the Hello World project, look at what you need to do. Those who have used IDE are very familiar with the concept of breakpoints, single-step operation, and Eclipse has debugging features that all IDEs should have. The debugging steps are as follows: 1. First set a breakpoint in the program, double-click the gray area on the left of the statement, then a breakpoint is added to the statement, as shown in Figure 7;
Figure 7 Set breakpoint
2. Click the debug button (a bug) in the toolbar; 3. Select HelloWorld; 4 under the Java application. Click "Debug" and the program will run to the breakpoint set up, then stop running; 5. Press F6, single step, and then the program runs to the next statement; 6. Press F8 to continue to run to the end of the program.
Import JUnit Example
Below we import a real project, this project comes from an example of Eclipse JDT. 1. Select file → import; 2. Select "ZIP file"; 3. Browse and find the location where the source code JAR file is located, enter junit; 4 in the folder; Click "Finish" to import a new JUnit project, as shown in Figure 8.
Figure 8 Import item