Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does it mean when you say C# is component oriented language?

Tags:

I learned Java while ago. I just got bored of Java and returned to C++ after a while. I thought that C# was similar to Java. My assumption about the similarities between C# and Java was not correct after some reading about C#. I found many powerful concepts in C# that I love to see in Java. Anyway, much of what I read made sense to me except one thing. I keep hearing that C# is component oriented language! Wikipedia was really useless about this concept.

What does it mean in simple terms when you say, C# is component oriented language?! A simple example would be appreciated.

like image 207
Khaled Alshaya Avatar asked Aug 05 '09 16:08

Khaled Alshaya


People also ask

What is the rule of pronouncing C?

The "Rule of c" covers the pronunciation of the letter "c", indicating when "c" stand for the /s/ sound. The rule is: The letter c represents /s/ before the letters e, i or y; otherwise it represents /c/.

What sound does C mean?

In English the letter 'c' is mostly pronounced as a /k/ sound. We can also pronounce 'c' as an /s/ sound.

What language does c mean yes?

C means "See or Si ("yes" in Spanish)".


2 Answers

I'm sure that others here will be able to give a better explanation of what component oriented languages are (and if they won't, a thorough search on the internet should) but the way I see it the component oriented paradigm can be viewed as an embodiment of object oriented programming.

That is to say that component oriented programming specializes Object Oriented Programming by strictly enforcing and implementing some OO concepts. Basically the whole idea is to create reusable code - in the form of components - that can be interchanged. So, component oriented programming heavily relies on: polymorphism, encapsulation, late binding, inheritance (through interfaces) and most importantly binary re-usability.

A component is a software package that encapsulates data and functionality - much like an object in OOP - but at a higher level.

So, to say that C# is a component oriented language is basically to say that it is very well suited to be used to develop such software packages which we call components - but I feel that the fact that C# targets the .NET framework has a lot to do with the statement.

In reflection we could probable say that Java can be considered a component oriented language as well - although I have to admit I don't have a broad knowledge of Java.

like image 57
Mike Dinescu Avatar answered Sep 28 '22 05:09

Mike Dinescu


I feel that the line between "component-oriented" and "object-oriented" is very blurry and in most cases it is safe to assume that they are the same thing.

That being said (and given the fact that I am unaware of your knowledge about object-oriented programming) I submit this excellent Wikipedia article for you to read:

Object-oriented programming (OOP) is a programming paradigm that uses "objects" – data structures consisting of datafields and methods – and their interactions to design applications and computer programs. Programming techniques may include features such as information hiding, data abstraction, encapsulation, modularity, polymorphism, and inheritance. It was not commonly used in mainstream software application development until the early 1990s. Many modern programming languages now support OOP.

You may also want to read Component-based software engineering which applies similar concepts across an entire system:

Component-based software engineering (CBSE) (also known as component-based development (CBD)) is a branch of software engineering, the priority of which is the separation of concerns in respect of the wide-ranging functionality available throughout a given software system. This practice brings about an equally wide-ranging degree of benefits in both the short-term and the long-term for the software itself and the organisation that sponsors it.

Components are considered to be part of the starting platform for service orientation throughout software engineering, for example Web Services, and more recently, Service-Oriented Architecture (SOA) - whereby a component is converted into a service and subsequently inherits further characteristics beyond that of an ordinary component.

like image 45
Andrew Hare Avatar answered Sep 28 '22 03:09

Andrew Hare