Java Topics

Features of Java

 Features of Java

  1. The primary objective of Java programming language creation was to make it portable, simple and secure programming language.
  2. The features of Java are also known as java buzzwords.

  • Simple: Java is very easy to learn, and its syntax is simple, clean and easy to understand.
  • Object-oriented: Java is an object-oriented programming language. Everything in Java is an object which has some data and behaviour. Basic concepts of OOPs are Object, Class, Inheritance, Polymorphism, Abstraction, Encapsulation
  • Platform Independent: Java is platform independent because it is different from other languages like C, C++, etc. which are compiled into platform specific machines while Java is a write once, run anywhere language. On compilation Java program is compiled into bytecode. This bytecode is platform independent and can be run on any machine. Any machine with Java Runtime Environment can run Java Programs.
  • Secured: Java is best known for its security. With Java, we can develop virus-free systems. When it comes to security, Java is always the first choice.
  • Robust: Robust simply means strong. For example java uses strong memory management, in java there is automatic garbage collection which runs on the JVM to get rid of objects which are not being used by a Java application anymore. Java makes an effort to eliminate error prone codes by emphasizing mainly on compile time error checking and runtime checking.
  • Architecture-neutral: Java is architecture neutral because there are no implementation dependent features, for example, the size of primitive types is fixed. Compiler generates bytecodes, which have nothing to do with a
  • Portable: Java is portable because it facilitates you to carry the Java bytecode to any platform. It doesn't require any implementation. Everything related to storage is predefined, example: size of primitive data types.
  • High-performance: Java is faster than other traditional interpreted programming languages because Java bytecode is "close" to native code. Java enables high performance with the use of just-in-time compiler. Java is an interpreted language, so it will never be as fast as a compiled language like C or C++.
  • Distributed: Java is distributed because it facilitates users to create distributed applications in Java. RMI and EJB are used for creating distributed applications.
  • Multi-threaded: A thread is like a separate program, executing concurrently. We can write Java programs that deal with many tasks at once by defining multiple threads. Benefit of multithreading is that it utilizes same memory and other resources to execute multiple threads at the same time.
  • 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++.
  • Large Standard Library: One of the reasons why Java is widely used is because of the availability of huge standard library. The Java environment has hundreds of classes and methods under different packages to help software developers like us. For example java.lang package, java.util package, java.io package etc.

No comments:

Post a Comment