Strengths and weaknesses of objects
InTech, Oct 2006 by Orr, Joel
"Software engineering" was an oxymoron for many years; programming was more of a black art than an engineering practice.
However, in the 1960s, a new paradigm appeared that has quietly transformed that world and influenced measurement, control, and automation ever more: Object-oriented programming (OOP).
OOP is bringing us the long-sought elusive promise of re-usable code, and of truly extensible systemsprograms that can be scaled without multiplying their complexity. That means higher software reliability, greater maintainability, and lower costs.
Programming before objects was procedural; it was like building an apartment building. Objectoriented programming resembles the construction of houses in a field.
Think about the differences between a 10-story apartment building with 10 apartments on each floor, and a development with 100 individual houses. The development is more expensive to construct than the apartment building, because each house has its own utilities and more walls per dwelling unit. In the apartment building, units share walls, and the ceiling of one level is the floor of the next.
On the other hand, adding a dwelling unit to the apartment building is difficult and expensive, while an additional house in the development costs no more, in principle, than any of the first hundred.
A short course in object-oriented programming: Objects group into classes and have methods associated with them; we say an object belonging to a class is an instance of that class.
For the experts to formally consider a programming environment object-oriented, it must support four behaviors:
1. Inheritance means new objects in a class "inherit" the characteristics of the class, although those characteristics can be individually modified by the programmer.
2. Encapsulation means objects contain data and methods-behaviors that are triggered under certain conditions.
3. Information hiding refers to an encapsulation in which certain details are not visible; for example, when you think of a car you do not think of all its components, nor necessarily of how it works.
4. Polymorphism refers to the ability of a single message to "mean" different things to different objects.
Programming in an object-oriented environment consists of the creation of classes of objects that will collaborate to produce the desired effects. Debugging object-oriented programs can be very simple, or terrifyingly complex, depending on how well written they are.
"The object-based approach promises to make software easier to reuse, refine, test, maintain, and extend," said Brian Wilkerson of Apple. "But simply implementing an application in an objectbased language does not guarantee these benefits. They can only be achieved if the implementation is based on a sound object-based design."
Adding capabilities to properly designed objectoriented programs is much easier than enhancing procedural programs, just as it is easier to add another house to a development than to add an apartment to an apartment building. Houses and objects are largely self-contained; the original plans of the apartment buildings and procedural programs completely determine and define them.
The qualities of object-oriented programs make possible the creation of "software components"pieces of code that work in many programs with little integration effort. It is this promise more than any other that has attracted adherents to OOP.
The power of objects is in their robustness, extensibility, flexibility, and modularity. Their principal weakness, for now, is performance, which varies widely.
Actually, I wish engineers did not have to know about objects; except as interesting metaphors, they are not useful to anyone but computer professionals.
ABOUT THE AUTHOR
Dr. Joel Orr (Joel.orr@cyonresearch.com) is vice president and chief visionary at Cyon Research Corp. He will be at ISA EXPO 2006 as a panelist at "Dick's Last Retort."
- 5 Rules for Immediate Annuities
- Death in the Family: 12 Things to Do Now
- Dumbest Things You Do With Your Money
- 6 Online Networking Mistakes to Avoid
- 401(k) Mistakes to Avoid
- 5 Economic Scenarios to Keep You Up at Night
- The Real ‘Best Places to Retire’
- Best Credit Cards for You
- 12 Tough Questions to Ask Your Parents
- The Real ‘Best Colleges’
- Home Buyer Tax Credit: How to Cash In
- Why You Shouldn't Bash Cash
- 8 Phony 'Bargains' and Better Alternatives
- Danger: 3 Debit Card Scams to Avoid
- 6 Myths About Gas Mileage
- 29 Fees We Hate Most
- Quick and Easy Ways to Boost Returns
- Best Stocks to Buy Now
- Lower Your Taxes: 10 Moves to Make Now
- New Jobs: 8 Lessons from Real-Life Career Switchers
- The New Job Market: Who Wins and Who Loses?
- Health Care Reform's Public Option: Everything You Need to Know
- Volunteer Work When Unemployed: Should You Work for Free?
- Whose Recovery Is This?
- Long-Term-Care Insurance: 4 Biggest Risks to Avoid
Content provided in partnership with
Most Recent Technology Articles
Most Recent Technology Publications
Most Popular Technology Articles
- BizRate to monitor in-store customer satisfaction for Office Depot stores - Market Intelligence
- Speed control of separately excited DC motor
- Effects of creative, educational drama activities on developing oral skills in primary school children
- Political stability and economic growth in Asia
- Failed businesses in Japan: a study of how different companies have failed, and tips on how to succeed, in the Japanese market



