• Post Reply Bookmark Topic Watch Topic
  • New Topic

How can i know that my program using OOP technique  RSS feed

 
Steven Gunanto
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi im newbie here.When i write program how i can know that my program are using technique OOP.
If i use these techniques like encapsulation,inheritance,or composition i can say my program using OOP technique ?

thanks in advance
 
Michael A Hoffman
Ranch Hand
Posts: 37
Java jQuery Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
To borrow from Object-Oriented Modeling and Design by Rumbaugh, Blaha, Premerlani, Eddy and Lorensen:

"Superficially the term 'object-oriented' means that we organize software as a collection of discrete objects that incorporate both data structure and behavior... There is some dispute about exactly what characteristics are required by an object-oriented approach, but they generally include four aspects: identity, classification, polymorphism and inheritance."

That said, most people don't measure how OO their code is. They measure other things, such as how maintainable the code is, how flexible the code is to changes, how easy the code is to test, how easy the code is to read, etc. With these in mind:

- Are you using design patterns and using them as intended? Design patterns are powerful and proven and can help achieve code that is built in a manner that extends the life of the software.
- The test-driven development community has done a good job of preaching, "if your code is hard to test, you are probably writing bad code." I agree with this in principle. There is, of course, a lot more involved in this message, much of which guides OO principles. Modeling smaller components, loose coupling, clear behavior naming, etc.
- Are you programming to interfaces?

I suggest reading Freeman and Pryce's book Growing Object-Oriented Software Guided by Tests, http://www.amazon.com/Growing-Object-Oriented-Software-Guided-Tests/dp/0321503627
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!