You are here:   HomeC# Programming
by Dinesh Thakur Category: OOP's in C#

Inheritance is a mechanism of sharing the members among the classes. Inheritance means taking an existing class and adding functionality by deriving a new class from it. The class you start with is called the base class, and the new class you create is called the derived class.

 
by Dinesh Thakur Category: OOP's in C#

One can create new reference types by defining classes. Classes provide templates' from which these direct instances are generated. Where we appeal to the relation between a class and its corresponding reference type instances we shall say that a class specifies the type (also that the class specifies the constitutive elements of the type)

 
by Dinesh Thakur Category: OOP's in C#

Method overriding means same name methods in different classes.

Polymorphism is a feature to use one name in many forms. There ·Polymorphism can be achieved in following ways in C#:

 
by Dinesh Thakur Category: OOP's in C#

Object-Oriented programming emphasis on data rather than function.

Object-Oriented programming was developed due to the limitations of the traditional programming approaches. The traditional programming approaches, such as Pascal, C, BASIC, FORTRAN and etc., are basically called procedural-oriented programming languages.

 
by Dinesh Thakur Category: OOP's in C#

Constructor is method of class to allocate the memory of object and initialize the variables of class.

 

When you declare a variable of a class, a special method must be called to initialize the members of that class. This method is automatically provided for every class and it is called a constructor.



 
by Dinesh Thakur Category: Advanced C#

The Collection namespace of System contains many classes and interfaces, which provides to define various collections of objects. These interfaces and classes are useful for every programmer to develop big or large applications.

 
by Dinesh Thakur Category: Advanced C#

In object-oriented languages, objects expose encapsulated functions called methods. Methods are encapsulated functions which run when they are invoked.

Sometimes, however, we think of the process of method invocation more grandly. In such a case, the method invocation is termed an 'event', and the running of the method is the 'handling' of the event. An standard example of an event is a user's selection of a button on a graphical user interface; this action may trigger a number of methods to 'handle' it

 
by Dinesh Thakur Category: Advanced C#

Delegate is a method template which used to implement the concept of function pointer.

 

The C and C++ languages are having the concept of function pointer. This was even more useful when programming for the Microsoft Windows operating systems because the Win32 library relies on the concept of callback functions. Callback functions are used in Microsoft Windows programming to process messages. For this reason and because of their functionality, callback functions were carried out in the .NET Framework but they were defined with the name of delegate.

 
by Dinesh Thakur Category: Advanced C#

Another important and exciting feature object-oriented programming is Operator overloading. C# supports the concept of operator overloading.

Operator overloading is a concept in which operator can defined to work with the userdefined data types such as structs and classes in the same way as the pre-defined data types.



 
by Dinesh Thakur Category: Advanced C#

An indexer is a member that enables objects to be indexed in the same as an array.

If properties are 'virtual fields', indexers are more like 'virtual arrays'. Indexers permit instances of a class or struct to be indexed in the same way as arrays. Indexers are similar to properties except that their accessors take parameters. They allow a class to emulate an array, where the elements of this array are actually dynamically generated by function calls.

 

Page 4 of 6



Subscribe To Free Daily Newsletter!

Get Free News Updates Delivered Directly To Your Inbox
About Dinesh Thakur

Dinesh ThakurDinesh Thakur holds an B.SC (Computer Science), MCSE, MCDBA, CCNA, CCNP, A+, SCJP certifications. Dinesh authors the hugely popular Computer Notes blog. Where he writes how-to guides around Computer fundamental , computer software, Computer programming, and web apps. For any type of query or something that you think is missing, please feel free to contact us.



What's New and Popular





Search Content







Advance Courses



Basic Courses



Advertise with Us