Extension method: Difference between revisions

Content deleted Content added
Extension methods: add the info back in summarized form.
m Extension methods: fix lang name
Line 39:
The major difference between extension methods and normal, static helper methods is that static methods calls are [[Polish_notation|prefix notation]], whereas extension methods calls are in [[Infix_notation|infix notation]]. This leads to more readable code when the result of one operation is used for another operation.
 
;With static methods: <source lang="csharp">HelperClass.Operation2(HelperClass.Operation1(x, arg1), arg2)</source>
 
;With extension methods: <source lang="csharp">x.Operation1(arg1).Operation2(arg2)</source>