logo

Principles, Characteristics and Features of Programming in Java

6 Pages1044 Words398 Views
   

Added on  2019-09-20

About This Document

This article discusses the principles, characteristics and features of programming in Java. It covers the simplicity, object-orientation, platform independence, security, robustness, portability and multi-threading features of Java. It also explains the three essential principles of Java language, which are encapsulation, inheritance and polymorphism. Additionally, it evaluates the role of Java Virtual Machine (JVM) and the environmental flexibility of programming in Java.

Principles, Characteristics and Features of Programming in Java

   Added on 2019-09-20

ShareRelated Documents
Q 1) Java has many features including Object Oriented, Platform Independent, Robust, Interpreted, and Multi-threaded. Discuss the principles, characteristics and features of Programming in Java?Ans: Characteristics and Features of Java1.Simple: According to Sun, Java language is simple because its syntax based on C++. If aprogrammer is familiar with C++, then it is easy to learn quicker Java language. Someconcepts removed from this language that makes developer confused, for example,explicit pointers, operator overloading, etc. It also eliminates the greatest headache forthe developer, and that is removing the unreferenced objects. Java provides AutomaticGarbage Collection.2.Object- oriented: Java is an object-oriented programming language. By using thislanguage, we can easily organize our software as a combination of different types ofobjects. Each object has own data and behavior. This methodology simplifies softwaredevelopment and maintenance by providing some set of rules or principles.3.Platform Independent: As we know platform belongs to hardware or softwareenvironment in which a program runs. Java provides the software-based platform thatruns on the top of other hardware-based platforms. Java has two important components:a)Runtime Environmentb)API (Application Programming Interface)
Principles, Characteristics and Features of Programming in Java_1
Note: Java code can run on any platform for example: Windows, Linux, Sun Solaris,Mac/OS, etc.4.Secured: Java is secured language because there are no explicit pointer and Javaprograms run inside virtual machine sandbox. Here is the diagram describes the apparentdifference
Principles, Characteristics and Features of Programming in Java_2
Classloader: It separates the package for the classes of the local file system from thosefiles that imported from network sources. Bytecode Verifier: It checks the fragments of code for illegal code that can violateaccess right to objects. Security Manager: It determines what type of resources a class can access such asreading and writing to the local disk.5.Robust: Java uses proper memory management. Java eliminates pointer concept that wasa cause of weak security. Java provides automatic garbage collection. There are exceptionhandling and type checking mechanism in Java. All these make Java robust. 6.Portable: We can run the Java bytecode on any platform.7.Multi-threaded: A thread is a part of a program which cannot break further. Java basedon multithreading concept. Threads shares common memory. They do not need separatememory to run. They run concurrently. It reduces the execution time, and it increases theperformance. Principles of Java LanguageThere are three essential principles.1.Encapsulation: Encapsulation wraps the attributes and the behavior. Encapsulationprovides security by covering things in the single unit. Encapsulation preventsunauthorized access to a class from outsiders. For example: a class combines attributesand methods in a single unit.2.Inheritance: The main advantage of Inheritance of code re-usability. A class inherits oruses the features of already exists class; this is called inheritance (reusing the code).There are two types of classes. One is the parent or super (this already exists, or we can
Principles, Characteristics and Features of Programming in Java_3

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents
Tax Calculator Java - Features, JVM, UML, Implementation, NetBeans IDE
|21
|3435
|286

Features of Java | Object Oriented Programming in Java
|13
|1682
|142

Features of Scrub Programming Language
|13
|3752
|1

2D pokemon jirachi: A Language Based on JAVA
|20
|4845
|38

Medicare Booking System | Report
|8
|1332
|20

Importance of Security Features in Programming Languages: A Focus on JAVA
|12
|2564
|340