J2SE Knowledge Summary __j2se

Source: Internet
Author: User

At this stage is preparing a soft test, need to learn the Java version of the design pattern, so learning J2SE became the first preparation, understand the basic Java grammar, for better learning design model to lay the groundwork.


The JAVA2 platform includes a Standard Edition (J2SE (Standard Edition)), an Enterprise Edition (Java EE (Enterprise Edition)), and a miniature version (J2ME (microedition)) three versions. Applied to basic knowledge learning (Jav language core classes), Enterprise-class development (applied classes, more comprehensive, more advanced), Consumer electronics software development (mobile phone, smart card, etc.). As a rookie, we first learn from J2SE, to master the most basic grammar. Look at this picture first:





One, for the Java overview, here is a few of his two major advantages (core mechanism):

1,java is a cross-platform very strong language, the implementation of a variety of platform to write a use. This is mainly based on one of its core mechanisms: Java Virtual machines:


2,java core mechanism 2: garbage collection processing will be done automatically without the programmer's precise control and intervention. Greatly facilitates the programmer's work.


Second, the basic syntax for Java, and vb,c# and other languages are the same, we need to learn to disagree: Here is just sketchy:



Three, object-oriented, is very important to the basics, I wrote this piece of knowledge in front of the blog:

Looking back--object-oriented, this is just applying these object-oriented knowledge to Java, and I think what we're going to do is look at the picture below me to recall, or say, this knowledge:



*: Before saying the following content, first say the importance of Java API documentation, download address: http://www.oracle.com/technetwork/java/javase/downloads/ Index.html, in fact, the following learning content can be said to be Learning Java API documentation, here first introduced the commonly used packages:





Four, for Java exception handling, I think and C # is very similar, but here the exception class feel a lot, need us to search API documents,

First look at the categories:


Throwable for all of its parent classes, like the tree in the data structure:



Of course, there are exceptions we need to capture, here and in C #, no longer too much to repeat:



Five, the array, this I think is not to mention, vb,c# is the same, the theory is the same. But the array design to multiple numbers, more two-dimensional, three-dimensional arrays, can be some of the complexity of the program, the algorithm becomes complex, we need to do the heart of these two points:



Of course, the analysis of memory needs us to practice by drawing constantly, the algorithm here just enumerated the simplest of several, we need to calm down to study these, will be in the soft test after the end of a short time to learn a variety of algorithms.

Six, commonly used classes, a chapter just learn some of the classes we often use, where we encourage you to read more Java API documentation, learning API documents to learn these classes, and master these classes:



Seven, containers, which we often use, such as heaps, stacks, sets, arrays, and so on, here are some of the things we often use:


One diagram is:


Simple explanation:



Or that sentence, through the API document to deepen learning.


Flow (Stream): Used in Java for data input/output operations. A simple diagram depicts the principle of input and output: This diagram describes the flow of inputs, outputs, nodes, and processes, and draws the various types of the two ends of the stream used to connect.


There are also a number of classifications for streams:



The four streams listed above are the most basic and important types, and we need to master, for node flow and process flow, we look at this picture to learn:






Nine, multithread processing mechanism:

1, Understand: The thread is an internal sequential control flow, that is, the CPU to deal with the matter, this matter has his order, complete this matter is the end of the thread. The simple understanding of multithreading is that CPU handles many things at the same time.

2, create: For the bottom two methods, the first one is more flexible than the second, because the thread interface is a method, in which case we can implement the interface without inheriting.


3, thread synchronization: For thread control methods, thread priority, which is easy to find in the API document, which I say a thread synchronization: In order to ensure the integrity of the data, at a certain time we can only allow specific threads to access this data. For example, we can't have two threads at the same time to modify the data. We introduce the bottom keyword to ensure that only one thread accesses an object at the same time:



Ten, network programming: This is for the current social trends, must learn, the network has been integrated into everyone's life.

1, first of all need to understand the network communication protocol layering, self-understanding is to facilitate the programmer, layered for us to provide the most convenient interface, the computer at the bottom of the interface for processing encapsulation. Detailed Reading Encyclopedia: Network layering.

2,IP protocol: Ensure that you can find the specified computer. It is the same as each of our students have a school number. Specific IP knowledge Read Encyclopedia: IP

3,TCP/UDP:


So how to connect two computers to communicate: you need



In this way, plus IP can connect two computers, you can do simple communication.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.