Let's start by looking at a set of data:
iOS and Android have accounted for 96% of the world's first mobile phones in the third quarter of 2014, according to the latest statistics from Strategy Analytics, the research body.
Among them, Android is still the absolute overlord, Hao take 83.6%, and compared with the same period last year grew 3%, iOS accounted for 12.3%, down 1.1%, the gap is still very obvious. Then the Windows Phone, which now accounts for 4.1%, has grown slightly, while the BlackBerry system has left only a pitiful 0.7%. Other operating systems total 0.1%.
There is no doubt that IOS and Android have become the two most mainstream mobile operating systems in the world. The Android system is a very poor and successful mobile operating system following iOS.
Now, what we want to consider is why does Android succeed?
You may say that "open source is the success of Android", yes, the most important factor for Android to succeed is open source, any handset manufacturer can be Google through the open source policy free access to the operating system, but also based on the operating system can be customized to create their own operating system (Android version of the custom)! It is also because of the Android system, has created a number of Samsung, Huawei, ZTE, Millet and many other domestic and foreign handset manufacturers success.
Of course, in addition to the "open source" for this reason, the operating system's own good features are also very important reasons, such as usability, ease of use, stability, security and functionality (also known as extensibility) and entertainment. The practicability, ease of use, stability and security of the operating system are determined by the operating system itself (for example, choosing Linux as the operating system kernel plus Google's ability to improve the basic features); The functionality and entertainment of the operating system is achieved through third-party applications, And this third-party program development abbreviation for Android Development, its development language is the famous java.
Now let's talk about Why Google chose the Java language as the development language of the Android system .
It said that the Android operating system is open source, its original intention is to integrate all the mobile phone hardware providers and mobile phone manufacturers, it is more essential to say that Google wants to allow Android to run on any different types of hardware, which is mainly the hardware of the CPU, including, high-pass, Texas Instruments, Samsung, and even domestic Huawei (HiSilicon processors). If you want an app (application) to run on a variety of platform devices, the development language must cross-platform (you might ask, "cross-platform" is relative to different operating systems, but the phone running Android is different, but the operating system is Android?) This is a common-sense problem, cross-platform includes two concepts, one is cross-operating system, the other is cross-hardware, and what we say is cross-hardware. ), by masking the differences in the underlying hardware across platforms without having to write different code for the programmer to consider the different underlying hardware. So who can cross-platform, compile and run everywhere and be efficient? is obviously Java. Of course, you can also say that Python is also possible, I just want to say that this thing is purely interpretive language, efficiency is too low. Why not use C or C + +? Oh, don't joke, they can't cross the platform; why not object-c? This is even more jokes, this east is Apple's son, not to say that he is not cross-platform, just Apple is Google's life and death opponents will not use; why not C #? The answer to this question is on the previous one; why not go, this is Google's own language ah?
For this question, you have to elaborate: Go is a compiled language, do not cross-platform, if you want to do cross-platform, Google must for go in the Android system to develop a set of runtime environment (runtime, similar to Microsoft's CLR and Oracle's JVM), and let go write the program first "compile" into an intermediate language, Then compile the machine code again in this set of "runtime environments". Maybe some friends will say, this is not the set of Microsoft's. NET (CLR) and Oracle's JVM do things, hehe, you are right, I believe that with Google's strength is very easy to do, After all, it is not difficult to develop a set of runtime environments or virtual machines (Davilik is the "JVM" that Google developed for Android). In fact, there is a very important reason, because the Java language is a fairly mature computer programming language, in addition to the basic library perfect, a variety of efficient third-party components are countless, the most important point is that the Java Virtual Machine specification is also open, Google can easily write a set of virtual machines in accordance with Oracle's virtual machine specification (the virtual machine is much easier than writing a "virtual machine" for go, and there are ready-made specifications). One reason for this is that there were too many programmers in Java at the time, and it was too easy for them to turn to Android (and the go was just starting, not many people)!
Ps:
1. Google's adoption of open source measures is a very time-out compromise policy, with underlying reasons:
At that time the market share of the iphone accounted for has been quite high, Saipan, BlackBerry and other bosses have revealed the decline, in this case:
On the one hand, other hardware manufacturers want to enter the market share;
Google, on the other hand, is the default search engine for iOS, but what if Apple and Google turn their back? Google can not take this risk, just then another android, so Google took advantage of the acquisition of the Android team, and the Andy Rubin incorporated into Google's first Google to Android is not too high expectations, only to poke an iOS knife, So a very compromised policy was adopted: fully open source, factory-independent customization.
2. Take the drawbacks of open source:
This drawback is now more serious, that is, open source causes fragmentation of the system and some device version lag problem. The optimism is that Google is now working hard to solve the problem.
3. What are cross-platform and technical essentials for cross-platform implementation?
cross-platform generic program language, software, or hardware devices can operate on a variety of operating systems or computers with different hardware architectures.
The core point of cross-platform is the support of "runtime/middleware Environment", which can be referenced in detail. NET's CRL and Oracle's jvm,http://blog.csdn.net/zhu_xun/article/details/40681105.
My opinion on why Android chooses Java as the development language