Media Preparation
Eclipse3.12 Download Address: http://www.eclipse.org/downloads/
XMLBean2.10 Download Address: http://xmlbeans.apache.org/sourceAndBinaries/index.html
jdk1.4+ or jdk1.5+ download address: http://java.sun.com/j2se/1.5.0/download.jsp
Note: If you use Weblogicserver, you can use the JDK in your product without having to install the JDK separately. Eclipse Configuration
Defined:
installation directory for%xmlbean_home%:xmlbean
%JAVA_HOME%:JDK installation directory
Building a Java Project
Because wants to use JDK1.5, therefore chooses 5.0, for the project management convenience, separates the original code and the generated binary file separately
Be sure to use the JDK insteadof the JRE, and if the default is JRE, redefine
Define a custom user class library and add all the jar packages under%xmlbean_home%/lib
Adjust eclipse to the resource view, then add dist to the root directory (to hold the generated jar packages) and schemas (for the schema file) directory
Create the Build.xml file on the root directory and define the Externaltools
Specify the ant script file to point to the Build.xml file you just created
Add all jars under%xmlbean_home%/lib to Classpath
Determines the use of the specified JDK
Test Modify Build.xml
The contents are as follows:
put the test schema file (easypo.xsd) in the schemas directory
The contents are as follows:
Perform
Show Ant View
associating Build.xml files
Double-click the anttask you want to perform, and there will be some error information, which can be ignored.
New You is (Dev2dev Id:guru), technical advisor to BEA Systems (China) Co., Ltd., a former business Objests technical advisor, and a technical advisor to the software company. |