09-09-2013, 04:19 PM
Java Features
Java Features[.doc (Size: 57 KB / Downloads: 19)
Simple
C ++ is an extension of C
Java has some features of C++.
It is simple because it does not has multiple inheritance, Operator overloading and pointers.(fig)
Platform Independent
Means it doesn’t require operating System to compile the program.(fig)
Any language is portable when it follows the following parameters:
1)it must be compiled in platform neutral manner
2)programs developed in that language don’t directly use the functionality of OS
3)The language has its own runtime environment for the eexecution of programs.
Portable
Portable and platform independent are different things.
Portable means , run on any OS .
WORA(Write Once Read Anywhere) concept was added to give definition of portability.
A language is said to be portable if the program developed in that language gives the same o/p across the platform without changing the source code.
This also means that the size of parameters will be fixed for all OS.
Robust(strong)
It has garbage collection (memory allocation and deallocation which occurs automatically)
And also it has run time error handing.
Distributed
It supports distributed programming…means it supports networking.(fig)
Dynamic
Dynamic means at run time…means java can have some code fragments that can be resolved at runtime.
Multithreaded
Threads are parts of a program .It helps in
1. Memory optimization.
2. CPU optimization.
Secure
Object oriented
In object oriented programming , data is represented by Objects.
Each object has 2 things fields and methods
Fields tell us what an object is and methods tell us what an object does.
Three OOPS principles
Class is a collection of objects that share common structure and behavior.
Encapsulation
It binds all the data together at one place and hide data from outside control(interference and misuse).
It includes data hiding for security if we don’t want anyone outside to acess the data and members.
To control that we also use access specifiers
Private
protected
Public