ابدأ بالتواصل مع الأشخاص وتبادل معارفك المهنية

أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.

متابعة

Why Java is not pure object oriented?

user-image
تم إضافة السؤال من قبل Rekha Ingulkar , BMC Software India Pvt. Ltd
تاريخ النشر: 2013/12/27
Mohd shahnawaz khan
من قبل Mohd shahnawaz khan , Associate Project , Cognizant Technology Solution

 Everything in Java is not considered as a Object, there are primitive data types available.Ex : for no.s we are using the int which is not a object type. (only Integer is object type ). 2) All features of OOP language is not fully supported by Java.Ex : Multiple Inheritance, Operator Overloading, etc. For a pure object oriented language,there should be6 features available with it.They are:-1.Encapsulation/Information Hiding2.Inheritance3.Polymorphisms/Dynamic Binding4.All pre-defined types should be Objects5.All operations performed by sending messages to Objects6.All user-defined types are ObjectsBut in java,features4 &5 are lacking.That'swhy it is not100%pure OO

Mukesh Kumar
من قبل Mukesh Kumar , Software Engineer , Team Computers Pvt. ltd

Java is not a pure object oriented language because it supports Primitive datatype such as  int, long, char, double… etc, to be used, which are not objects.

 

There are seven qualities to be satisfied for a programming language to be pure Object Oriented. They are:

Encapsulation 

Inheritance

polymorphisum 

Abstraction 

All predefined data type are object

All operation are performed by sendind message to object

All user defined type are object.

Deepak Kumar Shrivastava Dipu
من قبل Deepak Kumar Shrivastava Dipu , System Engineer , ibm

For a pure object oriented language, there should be6 features available with it. They are:-

1.Encapsulation/Information Hiding 

2.Inheritance 

3.Polymorphisms/Dynamic Binding 

4.All pre-defined types should be Objects 

5.All operations performed by sending messages to Objects 

6.All user-defined types are Objects 

But in java,

features4 &5 are lacking.That’s why it is not100%pure OO..

Because it contains eight primitive data types,these data types cannot be used as objects.

Smalltalk is pure OOP's.

 

Faizan Ahmad
من قبل Faizan Ahmad , Quality Analyst , US Tech Solutions Noida

1) Everything in Java is not considered as a Object, there are primitive data types available. Ex : for no.s we are using the int which is not a object type. (only Integer is object type ).  2) All features of OOP language is not fully supported by Java. Ex : Multiple Inheritance, Operator Overloading, etc.

Ananth G
من قبل Ananth G

primitive data type is used in java .so java is not pure object oriented 

himanshu nikhra
من قبل himanshu nikhra

A language to be a pure oops it should stick to the object whereeas in Java you can do something without using object .

e.g.

You want to print something ,System .out.println("Hello World") -Here you don't need to create any object directly you are using class ,you are using java  .

Hence Java in not pure oops

 

مستخدم محذوف‎
من قبل مستخدم محذوف‎

Its not Because it has data types(primitive data types) that are not objects

مستخدم محذوف‎
من قبل مستخدم محذوف‎

because it dosent support multiple inheritance .

 

but it is done by interfaces some what

 

Hatim Laxmidhar
من قبل Hatim Laxmidhar , Self Employed , The Way It Works

There is a very good discussion done in linked in.

Please have a look at this thread..

(لقد تم حذف الرابط بسبب انتهاكه لسياسة الموقع. يرجى التواصل مع قسم الدعم لمزيد من المعلومات.)

المزيد من الأسئلة المماثلة

هل تحتاج لمساعدة في كتابة سيرة ذاتية تحتوي على الكلمات الدلالية التي يبحث عنها أصحاب العمل؟