A partial class in .NET allows a single class
to be divided into two separate physical files. During compile time
these files get compiled into a single class.
Let us look at an example:
public partial class Employee
{
public void DoWork()
{
}
}
public partial class Employee
{
public void GoToLunch()
{
}
}
class MainClass
{
Static void Main()
{
Employee e = new Employee();
e.DoWork();
e.GoToLunch();
}
}
The trainers, programmers, and Subject
Matter Experts (SMEs) at SLA have developed a lucid and informative
courseware for .NET Technologies. If you want to be a part of this
wonderful learning experience, join SLA now!
For more details visit SLA Chennai or dial (91 44) 4200 5050/90.
For more details visit SLA Chennai or dial (91 44) 4200 5050/90.