Difference between Objects and Components
I want some clarification.
When it comes to enterprise applications why objects are being replaced by components.
Can any body helpme out
Thanks in advance
difference lies in the perspective.
while an object is an real programmatic entity, an instance of an class, a component is a view of some more complex code. a component can consist of more than one object. component is a more abstract term. you could say my webserver is a component of an bigger enterprise architecture. but you also could say a button is a component. usually components encapsulate some reusable functionality, are autonomous but can be connected to other components. i know, objects can do so as well. but object are, next to primitive types, the smallest entities available in programming languages, while components are usually bigger and have more common functions.
refer to the wikipedia definition. it says:
A software component is a system element offering a predefined service and able to communicate with other components. Clemens Szyperski and David Messerschmitt give the following five criteria for what a software component shall be to fulfill the definition: Multiple-use, Non-context-specific, Composable with other components, Encapsulated i.e., non-investigable through its interfaces, A unit of independent deployment and versioning
Very important for me is the "a system element offering a predefined service and able to communicate with other components". so the component encapsulates the functionality as an (aotonomous) service, connected to others.
There also is the following definition:
So you can see that components can be implemented as single or multiple objects and it's just the perspective to all of this.
A component is an object written to a specification. It does not matter what the specification is: COM, Java Beans, etc., as long as the object adheres to the specification. It is only by adhering to the specification that the object becomes a component and gains features like reusability and so forth.
By Zane Thomas in forum dotnet.announcements
Last Post: 10-17-2001, 10:51 PM
By Zane Thomas in forum .NET
Last Post: 10-17-2001, 02:37 AM
Last Post: 06-25-2001, 12:37 AM
By Chris Brown in forum VB Classic
Last Post: 02-08-2001, 06:47 AM
By Oliver Lennon in forum Enterprise
Last Post: 04-18-2000, 12:30 PM
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center