Features of Java

The main objective of Java programming language creation was to make it portable, simple and secure programming language.

A list of most important features of Java language are given below.
  1. Simple
  2. Object-Oriented
  3. Portable
  4. Platform independent
  5. Secured
  6. Robust
  7. Architecture neutral
  8. Interpreted
  9. High Performance
  10. Multithreaded
  11. Distributed
  12. Dynamic
  1. Simple:

    The Java language is easy to learn. Java code is easy to read and write.

  2. Object-Oriented:

    Unlike C++ which is semi object-oriented, Java is a fully object-oriented programming language. It has all OOP features such as abstraction, encapsulation, inheritance and polymorphism.

    Java is object-oriented programming language. Everything in Java is an object. Object-oriented means we organize our software as a combination of different types of objects that incorporates both data and behaviour.

    Object-oriented programming (OOPs) is a methodology that simplifies software development and maintenance by providing some rules.

    Basic concepts of OOPs are:
    1. Object
    2. Class
    3. Inheritance
    4. Polymorphism
    5. Abstraction
    6. Encapsulation
  3. Portable

    Java is portable because it facilitates you to carry the java bytecode to any platform. It doesn't require any type of implementation.

  4. Platform Independence:

    Java code is compiled into intermediate format (bytecode), which can be executed on any systems for which Java virtual machine is ported. That means you can write a Java program once and run it on Windows, Mac, Linux or Solaris without re-compiling. Thus the slogan “Write once, run anywhere” of Java.

    Besides the above features, programmers can benefit from a strong and vibrant Java ecosystem:

    • Java is powered by Oracle - one of the leaders in the industry. Java also gets enormous support from big technology companies like IBM, Google, Redhat,… so it has been always evolving over the years.

    • There are a lot of open source libraries which you can choose for building your applications.

    • There are many superior tools and IDEs that makes your Java development easier.

    • There are many frameworks that help you build highly reliable applications quickly.

    • The community around Java technology is very big and mature, so that you can get support easily.

  5. Secure:

    The Java platform is designed with security features built into the language and runtime system such as static type-checking at compile time and runtime checking (security manager), which let you creating applications that can’t be invaded from outside. You never hear about viruses attacking Java applications.

  6. Robust:

    With automatic garbage collection and simple memory management model (no pointers like C/C++), plus language features like generics, try-with-resources,… Java guides programmer toward reliable programming habits for creating highly reliable applications.

  7. Architecture-neutral

    Java is architecture neutral because there is no implementation dependent features e.g. size of primitive types is fixed.

    In C programming, int data type occupies 2 bytes of memory for 32-bit architecture and 4 bytes of memory for 64-bit architecture. But in java, it occupies 4 bytes of memory for both 32 and 64 bit architectures.

  8. Compiled and Interpreter:

    has both Compiled and Interpreter Feature Program of java is First Compiled and Then it is must to Interpret it .First of all The Program of java is Compiled then after Compilation it creates Bytes Codes rather than Machine Language.

  9. Distributed

    Java is distributed because it facilitates users to create distributed applications in java. RMI and EJB are used for creating distributed applications. This feature of Java makes us able to access files by calling the methods from any machine on the internet.

  10. Then After Bytes Codes are Converted into the Machine Language is Converted into the Machine Language with the help of the Interpreter So For Executing the java Program First of all it is necessary to Compile it then it must be Interpreter

  11. High Performance:

    Java code is compiled into bytecode which is highly optimized by the Java compiler, so that the Java virtual machine (JVM) can execute Java applications at full speed. In addition, compute-intensive code can be re-written in native code and interfaced with Java platform via Java Native Interface (JNI) thus improve the performance.

  12. Multithreaded:

    The Java platform is designed with multithreading capabilities built into the language. That means you can build applications with many concurrent threads of activity, resulting in highly interactive and responsive applications.

  13. Dynamic

    Java is a dynamic language. It supports dynamic loading of classes. It means classes are loaded on demand. It also supports functions from its native languages i.e. C and C++.

    Java supports dynamic compilation and automatic memory management (garbage collection).