From the category archives:

.NET

Yesterday, I’ve wrote in C#. I taken the code from the book. List.cs using System; public class List { const int defaultCapacity = 4; T[] items; int count; public List(int capacity = defaultCapacity) { items = new T[capacity]; } public int Count { get{return count;} } public int Capacity { get{return items.Length;} set { if(value…

A partial class or struct may contain a partial method. One part of the class contains the signature of the method. An optional implementation may be defined in the same part or another part. If the implementation is not supplied, then the method and all calls to the method are removed at compile time. Partial…

Partial Class C#.NET From Partial Class Definitions at MSDN, it is possible to split the definition of a class or a struct, or an interface over two or more source files. Each source file contains a section of the class definition, and all parts are combined when the application is compiled. There are several situations…