Hi there. 1
So, let’s begin the chapter by getting a high-level understanding of what Java is. 2
We will also see how Java is being used in the industry 3
So, what is Java? Java can be broadly defined as, a general-purpose, object-oriented, platform independent, 4
concurrent programming language that runs very fast 5
General-purpose implies that, it’s not constrained to one particular domain and can be used to develop wide 6
variety of applications. 7
Java is an object-oriented programming language and object-orientedness helps model real-world scenarios 8
in a more natural way. The concept of object and object oriented programming will be introduced later 9
Java’s mantra is Write Once, Run Anywhere, i.e., you write a program once and you must be able to run it 10
on any platform regardless of the operating system & architecture. 11
And this is referred to as platform independence. It is one of the key benefits of Java. Later in 12
the chapter. 13
we will see how this goal is achieved 14
in Java. Java supports concurrent programming, which is nothing but multi-threading; and this enables programs 15
to perform multiple activities at around the same time. Java is also very fast. It is almost indistinguishable 16
from C & C++. Later in the section 17
we will look at certain aspects of the Java platform, which make Java programs run very fast 18
These are some core attributes of Java. And these attributes make Java, a really solid, a very reliable 19
and a complete programming language. 20
It is currently one of the most widely used programming languages. 21
Java was also built on few additional principles and 22
let’s look at some of them. Java was invented in the mid nineties and most programmers during early nineties 23
were using C and C++. 24
So, Java’s designer’s wanted to keep the syntax familiar; 25
and so Java’s syntax is kept similar to C & C++. Simplicity was one of the most important goals for 26
Java’s designers. 27
So, in comparison to C & C++, they wanted Java to be easy to use. 28
For this reason, Java doesn’t have many features, which make C & C++ complex, confusing, and unsafe 29
One example is related to memory management. In C & C++, programmers directly manipulate memory to free 30
up space. 31
And if this is not done properly it can result in programs getting crashed. 32
In contrast Java is simple and safer as it provides automatic memory management using a feature called 33
garbage collection; and this relieves programmers from directly manipulating memory which in turn makes 34
programming task easier. 35
Garbage collection will be discussed in detail in the JVM internals chapter. Java is also secure. 36
And this is very important as Java programs can be downloaded from across the network and the downloaded 37
programs should not cause any harm to the user's computer. 38
So, we looked at some of the key principles of Java. 39
However, there are few other nice things that Java has to offer. 40
One of them is that Java comes with a rich library, which includes extensive pre-defined functionality and this 41
library is the Java API where API as you may know stands for Application Programming Interface. 42
This helps developers to focus on writing new logic without having to re-invent the wheel 43
i.e., they can simply make use of the pre-defined functionality, which is written by experts and is 44
already being used by millions of programmers. Java is also free. 45
And that's great for everyone including startups and even individual programmers. 46
It would help them to develop and launch their own products without having to invest a lot in the 47
software. 48
As we will see later, Java was initially developed to run inside embedded systems and later within 49
Web browsers in the form of Java programs called applets. 50
However it soon evolved as a popular language for developing large-scale Web applications, standalone desktop 51
applications and mobile applications. 52
Java provides separate dedicated platforms just for these different types of applications. 53
And this slide highlights how widely Java is adopted. All these large companies like Google, Netflix, Amazon 54
use Java. For instance, 55
Gmail is mostly written in Java. 56
Java was also used by NASA for their Mars Rover project called Spirit. 57
It seems one of the reasons they picked Java is due to its platform independence capability; and this also 58
tells that Java is truly general-purpose programming language 59
, i.e., it is not constrained to only commercial space. 60
Also, when it comes to open source libraries, probably most number of open source libraries are implemented 61
in Java. And the libraries that we see here are extremely popular. 62
For instance, companies like eBay & Apple use Apache Solr for providing search capability within 63
their Websites. Java is also extremely popular in domains such as search, data mining and machine learning, 64
which are very hot right now and they typically deal with very huge amounts of data. And here is a Job 65
requirement for a machine learning engineer position from Amazon.com in Bangalore, India. 66
And as we can see here the requirement is a solid understanding 67
in Java and object-oriented design; and this course is all about acquiring these skills. 68
So, that’s about what Java is? It was mainly designed to be simple, platform independent, and also very 69
stable and secure. 70
Performance wise it is very fast. 71
It supports concurrent programming and comes with a rich library 72
Thank you.