CSC/ECE 517 Fall 2012/ch1 1w17 ir: Difference between revisions

From Expertiza_Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
<big><big>'''Extending Objects'''</big></big>
<big>'''Extending Objects'''</big>
The ‘extend’ feature in computer programming languages allow the programmer to dynamically extend the functionality of an object at runtime, as opposed to extending functionality at compile time. This feature can be found in Object Oriented Programming (OOP) Languages.  
The ‘extend’ feature in computer programming languages allow the programmer to dynamically extend the functionality of an object at runtime, as opposed to extending functionality at compile time. This feature can be found in Object Oriented Programming (OOP) Languages.  
__TOC__
__TOC__


== Introduction ==
== Introduction ==
 
The programming paradigm OOP uses 'objects' for designing applications. These objects consist of an encapsulated set of data fields and methods, and are usually an instance of a class. These objects can communicate with each other through messages (or 'methods') and process data. But in order to increase an object's functionality, it is necessary to add the features of one object to another. This can be done dynamically at run time, without repeating the code, by extending the features of one class to another. This can be done by the use of the 'extend' keyword. Many OOP oriented languages support the 'extend' feature.
== Languages Using 'extend' functionality ==
== Languages Using 'extend' Functionality ==
===C++===
===C++===
===Java===
===Java===
Line 13: Line 13:
== Disadvantages ==
== Disadvantages ==
== Conclusion ==
== Conclusion ==
== See also ==
== References ==
== References ==
<references/>
<references/>
== Further Reading ==
== External Links ==

Revision as of 19:19, 8 September 2012

Extending Objects The ‘extend’ feature in computer programming languages allow the programmer to dynamically extend the functionality of an object at runtime, as opposed to extending functionality at compile time. This feature can be found in Object Oriented Programming (OOP) Languages.

Introduction

The programming paradigm OOP uses 'objects' for designing applications. These objects consist of an encapsulated set of data fields and methods, and are usually an instance of a class. These objects can communicate with each other through messages (or 'methods') and process data. But in order to increase an object's functionality, it is necessary to add the features of one object to another. This can be done dynamically at run time, without repeating the code, by extending the features of one class to another. This can be done by the use of the 'extend' keyword. Many OOP oriented languages support the 'extend' feature.

Languages Using 'extend' Functionality

C++

Java

Ruby

Python

Advantages

Disadvantages

Conclusion

See also

References

<references/>

Further Reading

External Links