C#

Examples of Connected and Disconnected Approach in ADO.NET

Today I will give some examples of the Connected and Disconnected Approach in ADO.NET. Basically, the ADO.NET library in .NET Framework provides the functionality for database access. This library offers lots of classes and methods for fetching and manipulating data from any data source. The following examples demonstrate how to perform database operations using these […]

Generic IList Interface and its Implementation in C#
C#

Generic IList Interface and its Implementation in C#

In this post I will discuss Generic IList Interface and its Implementation in C#. Basically, this interface is represented as IList<T> and it inherits from the generic ICollection and IEnumerable interfaces respectively. Significantly, this interface has applications in creating the generic lists as it provides several important properties and methods. Details of the IList Interface […]

IEnumerable and IEnumerator Interfaces
C#

IEnumerable and IEnumerator Interfaces

IEnumerable and IEnumerator Interfaces in C# have been implemented by a number of collection classes. Basically, these interfaces provide the functionality for traversing the elements of a collection. Basically, IEnumerator is something that can enumerate or visit the elements of a collection. Therefore, if any class implements IEnumerator, it has the ability to enumerate a […]

KeyValuePair and its Applications
C#

KeyValuePair and its Applications

Today I will discuss KeyValuePair and its Applications. Basically, it is a collection in C# that combines two objects together – one is called a key, and another one is called a value. Essentially, it is a generic struct. The namespace System.Collections.Generic contains the KeyValuePair struct. Creating a KeyPaluePair We use the constructor KeyValuePair<TKey, TValue)(k, […]