<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>.net and everything else....</title>
	<atom:link href="http://rbgautam.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://rbgautam.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Wed, 27 Oct 2010 03:52:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='rbgautam.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>.net and everything else....</title>
		<link>http://rbgautam.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://rbgautam.wordpress.com/osd.xml" title=".net and everything else...." />
	<atom:link rel='hub' href='http://rbgautam.wordpress.com/?pushpress=hub'/>
		<item>
		<title></title>
		<link>http://rbgautam.wordpress.com/2010/10/27/14/</link>
		<comments>http://rbgautam.wordpress.com/2010/10/27/14/#comments</comments>
		<pubDate>Wed, 27 Oct 2010 03:52:09 +0000</pubDate>
		<dc:creator>rbgautam</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rbgautam.wordpress.com/?p=14</guid>
		<description><![CDATA[user-guide<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=rbgautam.wordpress.com&amp;blog=12499822&amp;post=14&amp;subd=rbgautam&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href='http://rbgautam.files.wordpress.com/2010/10/user-guide.pdf'>user-guide</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rbgautam.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/rbgautam.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/rbgautam.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/rbgautam.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/rbgautam.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/rbgautam.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/rbgautam.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/rbgautam.wordpress.com/14/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=rbgautam.wordpress.com&amp;blog=12499822&amp;post=14&amp;subd=rbgautam&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://rbgautam.wordpress.com/2010/10/27/14/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fc57a4aacb26da4cd51324d460061baa?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">rbgautam</media:title>
		</media:content>
	</item>
		<item>
		<title>Application user guide</title>
		<link>http://rbgautam.wordpress.com/2010/10/27/application-user-guide/</link>
		<comments>http://rbgautam.wordpress.com/2010/10/27/application-user-guide/#comments</comments>
		<pubDate>Wed, 27 Oct 2010 03:50:12 +0000</pubDate>
		<dc:creator>rbgautam</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rbgautam.wordpress.com/?p=12</guid>
		<description><![CDATA[www.pw-inventory.com : Application user guide<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=rbgautam.wordpress.com&amp;blog=12499822&amp;post=12&amp;subd=rbgautam&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>www.pw-inventory.com : Application user guide</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rbgautam.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/rbgautam.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/rbgautam.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/rbgautam.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/rbgautam.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/rbgautam.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/rbgautam.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/rbgautam.wordpress.com/12/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=rbgautam.wordpress.com&amp;blog=12499822&amp;post=12&amp;subd=rbgautam&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://rbgautam.wordpress.com/2010/10/27/application-user-guide/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fc57a4aacb26da4cd51324d460061baa?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">rbgautam</media:title>
		</media:content>
	</item>
		<item>
		<title>.net 3.0 &#8211; Extension Methods</title>
		<link>http://rbgautam.wordpress.com/2010/03/09/extensionmethods/</link>
		<comments>http://rbgautam.wordpress.com/2010/03/09/extensionmethods/#comments</comments>
		<pubDate>Tue, 09 Mar 2010 06:44:14 +0000</pubDate>
		<dc:creator>rbgautam</dc:creator>
				<category><![CDATA[.net 3.0/3.5]]></category>
		<category><![CDATA[.net]]></category>
		<category><![CDATA[.net 2.0]]></category>
		<category><![CDATA[.net 3.0]]></category>
		<category><![CDATA[extension method]]></category>
		<category><![CDATA[static class]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[This article explains the concept of Extension methods in .net 3.0/3.5.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=rbgautam.wordpress.com&amp;blog=12499822&amp;post=1&amp;subd=rbgautam&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Extension methods are simple but very powerful feature of .net 3.0 framework.</p>
<p>Extension methods can be used as their name suggests to extend any built-in type in .net.</p>
<p>To explain the concept we will use an example of traditional way of adding a function to find if an int is even.</p>
<p>And then move on to the new concept of Extension method.</p>
<p>Traditionally, if you wanted to define a function to find if a number is even, then you would a utility class and then add the function as a Static function in that class.</p>
<p style="padding-left:30px;"><span style="color:#0000ff;">class</span><span style="color:#99ccff;"> <span style="color:#3366ff;">Utility</span></span></p>
<p style="padding-left:30px;">{</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">public static bool</span> isOdd(<span style="color:#0000ff;">int</span> value)</p>
<p style="padding-left:60px;">{</p>
<p style="padding-left:90px;"><span style="color:#0000ff;">return</span> (value %2 !=0);</p>
<p style="padding-left:60px;">}</p>
<p style="padding-left:30px;">}</p>
<p>The usage would be as follows:</p>
<p style="padding-left:30px;"><span style="color:#0000ff;">private static void</span> CheckEven(<span style="color:#0000ff;">int</span> num)</p>
<p style="padding-left:30px;">{</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">if</span> (<span style="color:#3366ff;">Utility</span>.isOdd(num))</p>
<p style="padding-left:90px;"><span style="color:#3366ff;">Console</span>.WriteLine(&#8220;<span style="color:#800000;">{0} is Odd</span> &#8220;,num);</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">else</span></p>
<p style="padding-left:90px;"><span style="color:#3366ff;">Console</span>.WriteLine(&#8220;<span style="color:#800000;">{0} is Even</span> &#8220;, num);</p>
<p style="padding-left:60px;">Console.ReadLine();</p>
<p style="padding-left:30px;">}</p>
<p>And now moving on to the new feature of extension methods</p>
<p style="padding-left:30px;"><span style="color:#0000ff;">public static class</span> Extensions</p>
<p style="padding-left:30px;">{</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">public static bool</span> IsEven(this int value)</p>
<p style="padding-left:60px;">{</p>
<p style="padding-left:90px;"><span style="color:#0000ff;">return </span>(value % 2 == 0);</p>
<p style="padding-left:60px;">}</p>
<p style="padding-left:30px;">}</p>
<p>The usage is simple</p>
<p><a href="http://rbgautam.files.wordpress.com/2010/03/extension1.jpg"><img class="aligncenter size-full wp-image-6" title="extension1" src="http://rbgautam.files.wordpress.com/2010/03/extension1.jpg?w=386&#038;h=210" alt="extension method" width="386" height="210" /></a></p>
<p>As you can clearly see that the extended method IsEven appears automatically as a method of type int and is shown in the VS2008 intellisense.</p>
<p>We have defined the same CheckEven() function this time with an Extension method</p>
<p style="padding-left:30px;"><span style="color:#0000ff;">private static void</span> CheckEven(<span style="color:#0000ff;">int</span> num)</p>
<p style="padding-left:30px;">{</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">if</span> (num.IsEven())</p>
<p style="padding-left:60px;"><span style="color:#3366ff;">Console.</span>WriteLine(&#8220;<span style="color:#800000;">{0} is Even</span> &#8220;,num);</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">else</span></p>
<p style="padding-left:60px;"><span style="color:#3366ff;">Console.</span>WriteLine(&#8220;<span style="color:#800000;">{0} is Odd</span> &#8220;, num);</p>
<p style="padding-left:60px;"><span style="color:#3366ff;">Console.</span>ReadLine();</p>
<p style="padding-left:30px;">}</p>
<p>We will go through the extension method definition once again to understand how to define an Extension method:</p>
<p style="padding-left:30px;"><span style="color:#0000ff;">public static class</span> Extensions</p>
<p style="padding-left:30px;">{</p>
<p style="padding-left:60px;"><span style="color:#0000ff;">public static bool</span> IsEven(<span style="color:#0000ff;">this int</span> value)</p>
<p style="padding-left:60px;">{</p>
<p style="padding-left:90px;"><span style="color:#0000ff;">return </span>(value % 2 == 0);</p>
<p style="padding-left:60px;">}</p>
<p style="padding-left:30px;">}</p>
<p>There are a few simple rules which re used to define an Extension method, these are as follows:</p>
<ol>
<li>The      class in which the Extension method is to be defined should be static.</li>
<li>The      extension function itself should be public and static.</li>
<li>The      type which has to be extended should be the first parameter and also      should be preceded by the this keyword.</li>
</ol>
<p>As you can see that the Extension methods are very powerful and easy to use and if used properly with proper documentation can improve the reusability of a code. And which will help the developer community in the long run.</p>
<p><span style="text-decoration:underline;"><strong>Note:</strong></span> Extension methods are not natively supported in .net 2.0. To do so you have to make some changes as explained in<a title="extension-methods-in-net-2.0" href="http://kohari.org/2008/04/04/extension-methods-in-net-20/" target="_blank"> this nice article</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rbgautam.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/rbgautam.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/rbgautam.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/rbgautam.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/rbgautam.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/rbgautam.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/rbgautam.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/rbgautam.wordpress.com/1/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=rbgautam.wordpress.com&amp;blog=12499822&amp;post=1&amp;subd=rbgautam&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://rbgautam.wordpress.com/2010/03/09/extensionmethods/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fc57a4aacb26da4cd51324d460061baa?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">rbgautam</media:title>
		</media:content>

		<media:content url="http://rbgautam.files.wordpress.com/2010/03/extension1.jpg" medium="image">
			<media:title type="html">extension1</media:title>
		</media:content>
	</item>
	</channel>
</rss>
