Learn Java from now on!!!
1. What is the JRE
Java Runtime Environment Java operating environment
including Java virtual machines (JVM Java) and the core class libraries required by Java programs, if you want to run a well-developed Java program, you only need to install the JRE on your computer.
2. What is a JDK?
JDK (Java Development Kit Java Development Kit)
The JDK is available to Java developers, which includes Java development tools and the JRE. So with the JDK installed, you don't have to install the JRE separately.
3. Why the JDK contains a JRE
First, the development of the program, always need to run a look at the effect.
Second, and most importantly, the development tools in the JDK are actually written in the Java language application, in order to facilitate the use of the package as EXE file,
Without the JRE, these tools cannot be run.
The role and relationship of D:JDK,JRE,JVM
4, the JDK download
Official website http://www.oracle.com
5. Environment variable Configuration
XP system
Right click on desktop computer → select Properties → select advanced tab → Click environment variables → system variables below find path→ double-click path→
Add the Bin directory under the JDK installation directory to the leftmost and add a semicolon.
WIN7/WIN8 system
Right click on desktop computer → select Properties → select advanced system settings → select advanced tab → Click environment variables → find path→ in system variables below
Double-click path→ to add the bin directory under the JDK installation directory to the leftmost and add a semicolon.
6. Steps
(1): Configure Java_home First
In the system environment variable: new Java_home
Variable Value =d:\develop\java\jdk1.7.0_72
(2): Modify path again
Add in front of path:%java_home%\bin;
Fundamentals of the Java Language (overview of annotations and their classifications) (master)
1: What is a comment
The text used to interpret the description program.
2: Classification and explanation of annotations
(1): single-line comment format://text for comments
(2): Multi-line Comment format:/* Text of comment */
(3): Document comment Format: text of/** comment */(explained later)
Second, the Java Language Foundation (keyword overview and use) (master)
1: What is a keyword
is a word that is given special meaning by the Java language.
2: Features of keywords
The letters that make up the key are lowercase
3: Common Keywords
Class,public,static,void .....
4: Keyword Considerations
(1): Goto and const are reserved words in the Java language
(2): A high-level text editor like EditPlus has color changes to keywords
E: Exercise: Judging the following are the keywords
Class,helloworld,public,static,void,main,string,system
Iii. Java language Basics (Overview and composition Rules for Identifiers) (master)
"See the name and know It"
1: What is an identifier
Is the sequence of characters to use when naming classes, interfaces, methods, variables, etc.
2: Constituent rules of identifiers
(1): Uppercase and lowercase letters in English
(2): Numeric characters
(3): $ and _
3: identifier Considerations
(1): Cannot start with a number
(2): cannot be a keyword in Java
(3): Case sensitive
Iv. Java language Fundamentals (common naming conventions in identifiers) (understanding)
1: The package (is the folder, it exists in order to solve our same directory can not exist at the same time two files of the same name.) )
The letters are all lowercase.
Single-stage package: Itcast
Multi-level package: Cn.itcast
2: Class or interface
One word: Capital letter, remaining letter lowercase student, Teacher, Spring, Struts, Hibernate
Multiple words: The first letter of each word is capitalized, the remaining letters are lowercase studentname, userlogincontroller
3: Method or Variable
A word: The letters are all lowercase name, age
Multiple words: Starting with the second word, the first letter capitalized, the remaining letters lowercase getName, getage
4: constant
A word: The letters are all uppercase name, age
Multiple words: Letters are all uppercase, use _ to separate each word student_max_age
First day of Java
Java language Basics