Anda di halaman 1dari 5

Dynamic Object Oriented Programming

Static Object-Oriented Programming


Object-oriented programming has become the undisputed successor to the structured methodologies because of its ability to better manage complexity. Modular software design, code reusability and rapid application development are just some of the many advantages of objectoriented technology.

As applications get larger, C++ tends not to scale (balance) well because changes increase the development cost in proportion to the size of the application rather than the degree of change. C++ requires any redesign in the classes and methods to be completely consistent and correct across the entire application source code before a design modification can be compiled, let alone tested. Any change in the classes causes the entire source to be recompiled, which in a large system can take hours. For this reason, programs written in C++ are monolithic and immutable, making it hard to redesign an application during development, and even harder to maintain and reconfigure software systems after an application is delivered.

This brittle(fragile) class problem remains a long-term weakness of C++. It makes it hard to incrementally develop software, impacting productivity, usefulness and maintainability of the final product.

In C++, objects are both a blessing and a curse. While a C++ program allocates objects all the time, it is not always clear when those objects go away. Very often objects refer to other objects in very complicated ways. Yet C++ does not provide any form of garbage collection to reclaim the memory used by defunct (outdated, obsolete, no-operational, redundant) objects. As a result, instead of working on the problem the application is designed to solve, a lot of a software
1

developer's effort - about half the total time needed to create an application - goes into dealing with a low-level systems problem that does not exist when using a dynamic language. More often than not, C++ developers resort to changing the application design to overcome memory management difficulties, resulting in an application that's less useful and less understandable.

Dynamic Object-Oriented Programming


Dynamic Object-Oriented programming is a software development technology that enables applications to be tailored during development and after deployment without access to source code. Dynamic OOP languages are much more effective than static OOP languages for managing complexity and adapting to changing needs.

With Dynamic OOP languages, the amount of work necessary to make a change is proportional to the degree of change, not the size of the application. New objects, new classes and new behavior can be added on the fly, and unlike static OOP languages, Dynamic OOP applications do not have to be rewritten to accommodate any change.

Dynamic OOP is the enabling technology for user-evolved software. Developers can incrementally test working prototypes with users, as Price Waterhouse did, resulting in significantly more usable applications. Developers have the freedom to try new things even when they aren't completely consistent with the rest of the application. Inconsistencies may eventually generate errors, but developers can still experiment with running the modified application. With Dynamic OOP, an application's behavior can continue to evolve after deployment. Dynamic OOP uses an additional level of abstraction called meta-data to achieve the magic of incremental change. At run time, an application's design is represented by meta-data that describes the class

hierarchy, objects and methods. Changes made to class definitions at run time, such as adding or deleting data members, cause the meta-data, not the objects themselves, to be updated. Whenever an object is accessed, it is first checked to ensure the meta-data describing it is current. If not, the object updates itself to conform to its new definition as described by the updated meta-data, and then normal processing resumes.

The change is incremental, and the application pays for the update only once per object access. This ensures the highest performance while retaining scalability. Moreover, this lazy evaluation technique ensures that even applications with millions of objects get their objects updated only on an as needed basis. In this way, the benefits of incremental change can be retained even in very large applications. Building similarly modifiable applications in static OOP languages would be extraordinarily difficult.

Because incremental change requires the system to completely understand the meta-data, it also provides the inherent benefit of automatic incremental memory management. The system knows when objects are no longer needed and automatically recycles the memory they consume. Thus, Dynamic OOP solves the memory leak problem common to static OOP applications, and allows programmers to concentrate on the application problem domain without the distraction of building memory management systems.

Dynamic OOP also presents some compelling advantages for software maintenance. It eliminates the very long recompile times, sometimes taking hours or days, required by static languages just to change a few lines of code. The use of meta-data permits layering new functionality into deployed systems dynamically, without access to the underlying source code. As a result,

systems can be upgraded electronically, by distributing new upgrade code. Dynamic OOP also enables developers to easily customize systems at user sites with minimal downtime.

The Promise of Dynamic OOP


The ability to dynamically change the behavior of an application enables rapid development times and quicker time to market because developers are able to alter the design to reflect their evolving understanding of the problem their application aims to solve. Dynamic OOP lets software developers create a new breed of user-modifiable shrink-wrapped applications frameworks that can be easily transformed into custom applications at a customer site without the need for source code. Dynamic OOP is able to achieve the goal of high configurability and low cost by leveraging the power available on the desktop to produce software that can be significantly modified easily, and inexpensively, by the customer.

Dynamic OOP also opens the door to creating new markets for exciting new applications like intelligent agents. The future will be filled with applications that can dynamically reconfigure themselves, a capability that will prove to be critically important especially in networked environments and on-line systems.

By combining the attributes of dynamic, interactive languages with object-oriented programming, it becomes possible to dramatically alter the behavior of an application by injecting a very small amount of data while the application is running. Using Dynamic OOP reduces network traffic and allows automatic generation of the custom code, off-loading the compute- and data-intensive components of the system. Compact software updates and bug fixes can be distributed over networks simply through email to thousands of computers without

monopolizing huge amounts of valuable network bandwidth. Creators of on-line system frontend applications no longer have to anticipate every conceivable service provider's need, enabling creative looks and functionality for new services by simply uploading very small files containing the necessary behavior to the end-user application at connect time.

Made practical by the explosion in desktop computing power, dynamic object-oriented languages have come of age and are ready to take their place on the software developer's workbench. They are the next step in the evolution of ever more powerful, easier to use development tools necessary for creating software in a rapidly changing world.

Anda mungkin juga menyukai