The tutorial for today is about StackOverflowException. The exception is thrown when the execution stack overflows by having too many pending method calls. This class cannot be inherited. Microsoft intermediate language (MSIL) instruction allocates a certain number of bytes from the local dynamic memory pool and pushes the address (a… Continue Reading C# – First steps with C# and .NET – part 034.
Many of the C# classes created today are simply collections of data to be transferred from one place to another. C# 9 introduces records, a new reference type that you can create instead of classes or structs. Records are distinct from classes in that record types use value-based equality. ,… Continue Reading C# – First steps with C# and .NET – part 033.
A benchmark is a measurement or a set of measurements related to the performance of a piece of code in an application. To work with BenchmarkDotNet you must install the BenchmarkDotNet package for benchmarking, see this webpage.
[mythcat@desk ~]$ cd CSharpProjects/
[mythcat@desk CSharpProjects]$ cd HelloWorld/
[mythcat@desk HelloWorld]$ dotnet add package BenchmarkDotNet --version 0.13.0
Determining projects to restore...
log : Restored /home/mythcat/CSharpProjects/HelloWorld/HelloWorld.csproj (in 47.99 sec).
The default source code of HelloWord is this:
static void Main(string args)
Let write methods… Continue Reading C# – First steps with C# and .NET – part 032 .
Serialization is the process of converting an object into a stream of bytes to store the object or transmit it to memory, a database, or a file. Its main purpose is to save the state of an object in order to be able to recreate it when needed. The reverse… Continue Reading C# – First steps with C# and .NET – part 031 .
System.Reflection Namespace Contains types that retrieve information about assemblies, modules, members, parameters, and other entities in managed code by examining their metadata. These types also can be used to manipulate instances of loaded types, for example, to hook up events or to invoke methods. To dynamically create types, use the… Continue Reading C# – First steps with C# and .NET – part 030 .
In C# the internal keyword can be used on a class or its members. Today I will show you how to use the internal accessibility level with members of the class. All types and type members have an accessibility level. The accessibility level controls whether they can be used from… Continue Reading C# – First steps with C# and .NET – part 029 .
A programming model which is mainly organized around the objects is called Object-Oriented Programming or the Programming named OOP. There are five basic pillars or concepts in OOP. Encapsulation Data Hiding Specialization Polymorphism Division of Responsibility Encapsulation is a process of binding data members (variables, properties) and member functions (methods)… Continue Reading C# – First steps with C# and .NET – part 028 .
The tutorial of today is about SOLID. There are three specific causes of change: adding new features, correcting faults, and restructuring code to accommodate future changes. This is the reason for the five design principles intended to make software designs more understandable, flexible, and maintainable known as SOLID. The SOLID… Continue Reading C# – First steps with C# and .NET – part 027 .