• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Java object based or object oriented

 
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is java object based or object oriented language? Java will not support 100% of oops concept not like smalltalk. How are we saying that java will not support 100% oops concept and why it is not supporting?
 
Ranch Hand
Posts: 808
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Java is object-oriented, not object-based. Older JavaScript was object-based, not object oriented.

Object-oriented: Can define or extend classes, and create (instantiate) objects.

Object-based: Can only create (instantiate) objects.


Because you are the one who posted the statement that Java is not 100% object-oriented like SmallTalk, perhaps you could tell us your reasoning.
 
lowercase baba
Posts: 13089
67
Chrome Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is sort of an academic argument. In order to answer it, you need to define EXACTLY what you mean by 'object based' and 'object oriented'. depending on how you define them, the answer could be neither, both, or only one...

To the OO purist, Java does not pass the muster, because it has things that are NOT objects - the primitive data types. Some people would also say the operators make Java non-pure-OO. I believe i've read that some languages, you can only have methods (which are parts of objects), so again, Java fails that test.

but, Java does support the main OO principles...

so, unless and until everyone can agree on what your terms mean (and believe me they don't), you're not gonna get a single, defining answer.
 
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
SmallTalk is OO because the term OO was coined to describe Smalltalk. For anything else, your own opinion is as good as anybody else's.
 
sriram sundararajan
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Am getting confused with all answers.
Leave about object based or object oriented, will java supports all OOPS concepts or not? If not why?
 
Jeff Bosch
Ranch Hand
Posts: 808
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think you may be asking for a clear 100% answer for a question that has no clear 100% answers. Pretty much, if you read carefully the above responses, you'll have a consensus of the differing opinions on the subject.
 
fred rosenberger
lowercase baba
Posts: 13089
67
Chrome Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

will java supports all OOPS concepts or not?



What concepts are you interested in/worried about? Generally speaking, most people would say "Yes, Java supports OO concepts". But if you could give us a list of what YOU consider to be "all OOPS concepts", you could probably get a more definitive answer.

I'm really not trying to be a pain. but some people say "if it supports inheritence and encapsulation, it's OO".

Other would say "if you can create something that's NOT an object (in java's case, a primitive), then it's NOT OO".

So we really can't answer your question unless you clarify/define your terms.

sorry!!!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic