Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

object oriented

 
Puneet N Vyas
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what is the meaning of pure object oriented language,how we decide that a language is pure object oriented language,can we say java is pure object oriented language,if yes than how,if no then why??
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15207
36
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The question "Is Java a pure object oriented language?" is asked frequently here on JavaRanch. To answer this question, you first need to know what "pure object oriented" means. There is no exact definition for that term, so the question cannot be answered with exact precision.

OO purists would not consider Java a purely object oriented language, because in Java not everything is an object. There are for example primitive types which are not objects. In other programming languages, such as Ruby, everything is an object, so you could say that Ruby is more purely OO than Java.
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'd say that Java isn't as OO as other languages, such as Ruby or Smalltalk, but that the term "purely OO" has as much meaning as "purely hot" in cooking.

As an aside, you can easily write none-OO programs in OO languages; and (not as easily) OO programs in non-OO languages. With other words, OO languages just make it easier to write OO programs.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic