Java from getting started to mastering-formally moving to the Java Project development path

Source: Internet
Author: User
Tags learn php

Before many times will joke, say what, three days learn PHP, seven days proficient nodejs,xx day Learn xx ...

Generally speaking, this is mostly a little ironic, I also basically do not believe what quick start. I used to know a lot of languages when I was in school, but basically I just got a rough idea of what it was, and it certainly wasn't. At best, you can blow your mouth and say a few big ideas.

The company recently transformed, decided to abandon PHP, our way Out is: either H5, or Java, or leave. After a period of entanglement, I decided to turn to Java.

When a person in his familiar areas, as if to say that everything is confident, all feel that they are right. At that time our slogan is: All languages are similar, but the expertise is not the same, the language is not important! But when it comes to doing it yourself, to tell the truth, it's a guilty conscience. After all, I have been in the field of specialization for many years, is also a work experience. But now involves the transformation, oneself immediately will become the rookie, you also dared to say the thing as confidently as before.

Guilty to a guilty conscience, things are always to do, cows are always going to blow. So what is the solution? That is rapid learning, rapid growth, quickly become old birds.

So I picked up the book in sarcasm! JAVA from getting started to mastering. To tell the truth, after deciding on the shape, I have been quick to read a lot of Java books, but when I saw this from the introduction to mastery, I still look again. Think it is necessary to summarize, after all, experience is to summarize it!

Basic grammar I actually skipped, but a lot of the time still stepped on the pit, some of them listed can be. Tell me about one.

1. Basic Java features (WEB)
1.1 JAVA is a compiled language, you must first compile the source code once (JAVAC), generate a. class file, and then run (JAVA). This has two major benefits, one is not to repeat the previous compilation work in essence to improve the efficiency of operation, the second is during the compilation can do a lot of code reorganization and optimization work.
1.2 Java is running in the JVM, as long as a boot, will load all the relevant code to memory, although the memory, but can do a boot, permanent use of efficient use!
1.3 Java Getting started with the IDE, basically still choose the ancient eclipse as a tool, one is a long history of information can be consulted more people, and the second is that Eclipse does have his unique.
1.4 Tomcat as a web container to run, convenient and easy to get started, configuration aspects of the main attention to the same number of computers, open Tomcat alone, observe whether the error, the wrong to solve it.

1.5 The use of Java variables may differ from other languages, Java will find, current scope > Current class > Parent class, do not necessarily need the this keyword, and some languages have a certain difference.
1.6 Type Conversions
1.6.1 automatic conversion only from small to large, in order: byte > Short > Int > Long > Float > Double > Char
1.6.2 coercion type conversion, this attention point comparison multipoint, example: Integer.valueof ("123"). Intvalue (), float.valueof ("123"). Floatvalue (), long.valueof ("123 "). Longvalue (), character.valueof (" 123 "). Charvalue (), String b;b=a+" ";
Use object to save the intermediate type, and then revert to a specific type of conversion, such as:
Map<string, string> C = new hashmap<string, string> ();
C.put ("T1", "test1");
Object cc = c;
System.out.println ("C is:" + C + "& CC is:" + cc);
map<string, string> map = (map<string, string>) C;
SYSTEM.OUT.PRINTLN ("Covert map is:" + map);
1.6.3 size comparison, can only use the same type comparison, 1 = = 1, character comparison can only use "CC". Equals (Var); Switch (VAR) {} supports string judgments since jdk1.7.
1.6.4 objects are referenced by reference, and if you want to use a standalone object, you need to copy the content to the new memory, which differs greatly from some languages.
1.6.5 abstract classes, interfaces, require subclasses to implement the appropriate methods
Upward transformation and downward transformation of the 1.6.6 class
1.6.7 Equals, tostring Method

2. Java in-depth stuff
2.1 Inner classes: For basic only internal calls, static classes: Some common functions, written to this class, anonymous class: Used for disposable classes such as threading
2.2 Java Reflection (a bit confused, see more)
2.3 Java Collection classes: Map, HashMap, TreeMap, List, ArrayList, LinkedList, Set, HashSet, SortedSet, Interator

2.4 try{...} catch (..) { ... } Exception capture, throwing custom exceptions where needed

2.5 I/O, FileInputStream, FileOutputStream, FileReader, FileWriter, Bufferedinputstream, Bufferedoutputstream, BufferedReader, Bufferedwriter,zip ...

3. Swing Window Layout client development, for Web development is not useful, for the time being not read, in general, the use of various component layouts, add events ...

4. Multithreading
4.1 Thread class, runnable interface, new thread ("XXX"). Start (), Wait (), lock.notify (), notifyall (), yield, join, synchronized

5. Network communication (Socket)
5.1 tcp/ip:inetaddress, New ServerSocket (10003); New Socket ("192.168.1.88", 10003);
5.2 Udp/ip:new datagramsocket (); New Datagrampacket (buf,buf.length); New Datagrampacket (Buf,buf.length,inetaddress.getbyname ("192.168.1.88"), 10000);

6. JDBC Operations Database
Before using PDO, and this basically consistent, now using the connection pool, mybatis these things

7. Case studies
Just a look.

Because is in the project study, the case naturally is more, the quick Study basic knowledge, the project progress does not fall, is good.
At present, to see Java source code is still a lot of confusion, find ways!!!

Java from getting started to mastering-formally moving to the Java Project development path

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.