summaryrefslogtreecommitdiffhomepage
path: root/csharp.html.markdown
diff options
context:
space:
mode:
Diffstat (limited to 'csharp.html.markdown')
-rw-r--r--csharp.html.markdown10
1 files changed, 9 insertions, 1 deletions
diff --git a/csharp.html.markdown b/csharp.html.markdown
index 599aaca3..22fb58e1 100644
--- a/csharp.html.markdown
+++ b/csharp.html.markdown
@@ -523,6 +523,14 @@ namespace Learning
"\n------------------------------\n"
;
}
+
+ // Methods can also be static. It can be useful for helper methods
+ public static bool DidWeCreateEnoughBycles()
+ {
+ // Within a static method, we only can reference static class memebers
+ return bicyclesCreated > 9000;
+ } // If your class only needs static members, consider marking the class itself as static.
+
} // end class Bicycle
// PennyFarthing is a subclass of Bicycle
@@ -551,7 +559,7 @@ namespace Learning
* Flags
* Attributes
* Generics (T), Delegates, Func, Actions, lambda expressions
- * Static properties, methods and classes
+ * Static properties
* Exceptions, Interfaces, Abstraction
* LINQ
* ASP.NET (Web Forms/MVC/WebMatrix)