Panajev2001a
GAF's Pleasant Genius
Code:
public int Age
{
get
{
return age;
}
set
{
age = value;
}
}
The keyword value is implicitly available to the property. If you write
Fred.Age = 17;
the compiler will pass in the value 17 as value.
You can create a read-only property for YearsServed by implementing the Get and not the Set accessor.
public int YearsServed
{
get
{
return yearsServed;
}
}
http://msdn.microsoft.com/msdnmag/issues/01/07/ctocsharp/default.aspx
My second Linux kit for the PlayStation 2 (PAL version) has not arrived yet and I am starting to look at C# in themean-time... and it is pretty .
I think I will get the C# component for Visual Studio.NET 2003 soon.