mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-23 17:41:41 +00:00
[CSharp/en]Added static property
This commit is contained in:
parent
0387b6dbf1
commit
4f8b16f817
@ -625,7 +625,7 @@ on a new line! ""Wow!"", the masses cried";
|
|||||||
// Static members belong to the type itself rather then specific object.
|
// Static members belong to the type itself rather then specific object.
|
||||||
// You can access them without a reference to any object:
|
// You can access them without a reference to any object:
|
||||||
// Console.WriteLine("Bicycles created: " + Bicycle.bicyclesCreated);
|
// Console.WriteLine("Bicycles created: " + Bicycle.bicyclesCreated);
|
||||||
static public int BicyclesCreated = 0;
|
public static int BicyclesCreated { get; set; }
|
||||||
|
|
||||||
// readonly values are set at run time
|
// readonly values are set at run time
|
||||||
// they can only be assigned upon declaration or in a constructor
|
// they can only be assigned upon declaration or in a constructor
|
||||||
@ -827,7 +827,6 @@ on a new line! ""Wow!"", the masses cried";
|
|||||||
|
|
||||||
* Flags
|
* Flags
|
||||||
* Attributes
|
* Attributes
|
||||||
* Static properties
|
|
||||||
* Exceptions, Abstraction
|
* Exceptions, Abstraction
|
||||||
* ASP.NET (Web Forms/MVC/WebMatrix)
|
* ASP.NET (Web Forms/MVC/WebMatrix)
|
||||||
* Winforms
|
* Winforms
|
||||||
|
Loading…
Reference in New Issue
Block a user