Java application development involves the following steps: writing, compiling, and running. The following sections describe each other.
Java files are plain text files. Each Java application can contain one or more java files. The suffix of the Java file is. java. You can use various text editing tools to compile Java files, and save them to the. Java file. Each Java file usually contains a class or an interface, or multiple classes. Whether it is a single file or multiple files, there is usually an application portal (not an independent application, there can be no portal), through which the application is executed, this portalCodeAccess other files. Java files must be written in accordance with the Java language specification.
Compile: the Java file must be compiled before it can be run. The compiled file is a. Class file. The compiled bytecode is platform-independent and can be run on various platforms, provided that the platform supports JavaProgramThe Java virtual machine that runs. Compiling is a development tool javac provided by JDK (Java SE Development Kit. Note that the JDK version of the compiled Java file must be consistent with the JRE version of Java. Otherwise, errors may occur.
The. Class file is formed after the Java file is compiled. The class file is used during running. Java applications run through the Java commands provided in JDK. Java programs require a Java Virtual Machine to run. The cross-platform nature of Java is precisely because there are different virtual machines on different platforms. First, load the class, find the entry method, instantiate the class, and call the method...
Remember: the Java application development process includes compiling source files, compiling source files, and executing applications. Compile and use the javac command to run the Java command.
Last Lecture:Lecture 4: Three Java versions
Next Lecture:6. Write a Java application
Li xucheng csdn blog: http://blog.csdn.net/javaeeteacher
Csdn student base camp: http://student.csdn.net/invite.php? U= 124362 & C = 7be8ba2b6f3b6cc5