Explain features of Java/Java Buzzwords.
JAVA BUZZWORDS /features of Java
The primary objective of Java programming language creation was to make it a portable, simple, and secure programming language. Apart from this, there are also some excellent features which play an important role in the popularity of this language. The features of Java are also known as java buzzwords. Here are some terms that are used for java as its features:
Simple: According to Sun, Java language is simple because its syntax is similar to C and C++ and hence easy to learn after C and C++. Again confusing and rarely used features, such as explicit pointers, operator overloading, etc, are removed from java.
Object-Oriented: Object-oriented means we organize our software as a combination of different types of objects that incorporate both data and behavior. Java is a true object-oriented programming language that supports encapsulation, inheritance, and polymorphism. Almost everything in Java is an object.
Distributed: We can create distributed applications in java. Remote Method Invocation (RMI) and Enterprise Java Beans (EJB) are used for creating distributed applications. We may access files by calling the methods from any machine on the internet.
Robust: Robust simply means strong. Java uses strong memory management. There is a lack of pointers that avoids security problem. There is automatic garbage collection in java. There is an exception handling and type checking mechanism in java. All these points make java robust.
Secure: Security is an important concern since Java is meant to be used in networked environments. Applets running in a Web browser cannot access a Web client's underlying file system or any other Web site other than that from which it originated. Again, Java programs run in a virtual machine that protects the underlying operating system from harm. Also, the absence of pointers in Java ensures that programs cannot gain access to memory locations without proper authorization. . Furthermore, access restrictions are enforced (public, private) and byte codes are verified, which copes with the threat of a hostile compiler.
Architecture Neutral: Since Java runs inside of a Virtual Machine, the program does not depend on the underlying operating system or hardware. Java code can be run on multiple platforms such as Windows, Linux, Sun Solaris, Mac/OS, etc. Java code is compiled by the compiler and converted into bytecode. This bytecode is a platform-independent code because it can be run on multiple platforms. The phrase writes once, run anywhere is the major concept for the portability that Java adheres. This is because byte code will run on any operating system for which there exists a compatible Virtual Machine.
Compiled and Interpreted: Usually, computer language is either compiled or interpreted. Java combines both these approaches thus making Java a two-stage system. First, the Java compiler translates source code into what is known as bytecode instructions. Byte codes are not machine instructions and therefore, in the second stage, the Java Interpreter generates machine code that can be directly executed by the machine that is running the Java program.
High Performance: Java is faster than traditional interpretation since byte code is "close" to native code still somewhat slower than a compiled language (e.g., C++). The performance gain is due to the JIT (Just In Time) compilation that caches the recurring process to speed up the interpretation.
Multithreaded: We can write Java programs that deal with many tasks at once by defining multiple threads. The main advantage of multi-threading is that it shares the same memory. Threads are important for multi-media, Web applications, etc.
Comments
Post a Comment