summaryrefslogtreecommitdiffhomepage
path: root/csharp.html.markdown
diff options
context:
space:
mode:
authorMax Yankov <golergka@gmail.com>2013-08-17 22:49:36 +0200
committerMax Yankov <golergka@gmail.com>2013-08-17 22:49:36 +0200
commitbb1f4eb93a70882f959acf6e849a9663ad74deca (patch)
treea7a54e632155ec6e87d8aee958b534d52c5d9da5 /csharp.html.markdown
parent964476a6e859959a3c1ae6a005ba82ba0d6b234e (diff)
C#: edited example code according to Microsoft's naming conventions
Diffstat (limited to 'csharp.html.markdown')
-rw-r--r--csharp.html.markdown12
1 files changed, 6 insertions, 6 deletions
diff --git a/csharp.html.markdown b/csharp.html.markdown
index 584d40fd..0740c3ed 100644
--- a/csharp.html.markdown
+++ b/csharp.html.markdown
@@ -450,29 +450,29 @@ namespace Learning
// Method declaration syntax:
// <scope> <return type> <method name>(<args>)
- public int getCadence()
+ public int GetCadence()
{
return cadence;
}
// void methods require no return statement
- public void setCadence(int newValue)
+ public void SetCadence(int newValue)
{
cadence = newValue;
}
// virtual keyword indicates this method can be overridden
- public virtual void setGear(int newValue)
+ public virtual void SetGear(int newValue)
{
gear = newValue;
}
- public void speedUp(int increment)
+ public void SpeedUp(int increment)
{
_speed += increment;
}
- public void slowDown(int decrement)
+ public void SlowDown(int decrement)
{
_speed -= decrement;
}
@@ -521,7 +521,7 @@ namespace Learning
{
}
- public override void setGear(int gear)
+ public override void SetGear(int gear)
{
gear = 0;
}