Java Basic Development environment construction:
Windows+jdk+tomcat+eclipse+mysql;
1,jdk6.0: (To April 2011 is the newest)
Http://www.oracle.com/technetwork/java/javaee/downloads/index.html
Java EE 6 SDK with JDK 6
Or
Http://www.oracle.com/technetwork/java/javase/downloads/index.html
Java Platform (JDK)---now loaded with this;
(Jdk-6u24-windows-i586.exe)
2,tomcat6.0: (can also download the latest 7)
http://tomcat.apache.org/download-60.cgi
Core:32-bit/64-bit Windows Service Installer (PGP, MD5)
---the configuration of the zip failed, using the installation version;
(Apache-tomcat-6.0.32.exe)
3,eclipse IDE for Java EE developers/windows (3.62, up to April 2011 is the latest)
http://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/helios/SR2/ Eclipse-jee-helios-sr2-win32.zip
----free installation, handsome!
(Eclipse-jee-helios-sr2-win32.zip)
Chinese language pack;
http://www.eclipse.org/babel/downloads.php
Click "Helios" to download
Babellanguagepack-eclipse-zh_3.6.0.v20101211043401.zip (92.91%)
Use: The language extracted after the folder "Eclipse", directly copied to the "Eclipse\dropins" folder, you can;
4,mysql:
http://www.mysql.com/downloads/mysql/
Windows (x86, 32-bit), MSI Installer (Mysql-5.5.11-win32.msi)
National Taiwan University, Taiwan---http;
MySQL management tools;
Navicat; (Lite 9.19)
Http://www.navicat.com/cn/download/download.html
If there is a problem, download navicat windows 9.1.10, (download (including free support), first Register under;)
JDK installation, using the default installation is good;
JDK Configuration:
After the installation is complete, you also need to configure the Java environment for normal use, the steps are as follows:
(1): Right-click on My Computer--〉 select Properties,
(2): On the popup screen: Select Advanced--〉 environment variable,
(3): Find the "Path" in the system variable, and then double-click it, in the popup interface, the value of the variable open
The header adds the following statement "D:\common\Java\jdk1.6.0_02 (the installation path of the JDK ahead) \ bin;", take care not to forget the semicolon behind,
(4): Then click the OK button of the edit System variable interface, then click "New" in the environment variable interface.
(5): Fill in the above variable name: java_home, the variable value is: D:\common\Java\jdk1.6.0_02;, note
Meaning semicolon.
(6): Then click the OK button of the new system variable interface, then click "New" in the environment variable interface, pop up
New system variable interface, fill in the variable named: classpath, the value of the variable is:.; , note the dots and semicolons.
(7): Then click on the Click OK button, to this setting is complete.
So why set these environment variables and how to set them up:
Path: Provides paths to the operating system to find the Java command tool. Typically configured to the JDK installation path \ Bin, such as: D:\common\Java\jdk1.6.0_02\bin;.
Java_home: Available to other Java-based programs so that they can find the location of the JDK. Typically configured to the JDK installation path, such as: D:\common\Java\jdk1.6.0_02;. Note: Java_home must be written correctly, all uppercase, and underlined in the middle.
CLASSPATH: The provider finds the path to the required resources at run time, such as: classes, files, pictures, and so on.
Note: On the Windows operating system, it is best to classpath in the configuration, always in front of ".;" Of
Configuration, Inside Windows "." Represents the current path.
Fourth step: Detect the installation configuration is successful
Finish the above steps, the basic installation and configuration is good, how to know the installation is not successful?
Click Start--〉 Click Run, enter "CMD" in the popup dialog, then click OK, in the popup dos
window, enter "Javac", then return, the following interface appears to indicate that the installation configuration is successful.
Fifth Step: Test
(1) Write a simple Java program with a text editor:
public class HelloWorld {
public static void Main (String args[]) {
System.out.println ("Hello world!");
}
}
This example is known as "Hello World", and its function is to display "Hello World".
(2) Compile: Execute at DOS command prompt: (note case)---First go to the path (for example, placed in the e-packing directory, cmd e: Go to the e-packing directory,) and then:
Javac Helloworld.java
If normal, the Helloworld.class file is generated.
(3) Run: Execute at DOS command prompt: (note case)
Java HelloWorld
If normal, the Hello world! will be output.
Tomcat installation, download the installation version,
Can be set under "Select Installation Method", you can default, you can select full;
You can set the username and password for the next tomcat;
Run:
Start---program---tomcat, start the service;
Browser, http://localhost:8080/access to the Tomcat directory is successful;
Test:
Tomcat installation directory \webapps\examples\jsp\index.html, "execute" executes its JSP example below;
MySQL Installation:
Choose Setup Type, select Typical (typical installation);
< accessories, photo 1>
Select Manual Setting, set 100;
< accessories, photo 2>
set to UTF8;
< accessories, photo 3>
Tick the bottom of the selection;
< accessories, photo 4>
Set the password;
Complete the installation;
MySQL uses:
DOS command operation;
Installation reference:
Http://wenku.baidu.com/view/4de81840be1e650e52ea99ef.html
Java Development Environment Configuration