Overload Generic Method for Specific Data Type
<p>I have method that transforms some input value by the user passing it a Func delegate wich returns the new value (very over simplified for what I am trying to achieve)</p>

<pre><code>    public L Coerce&lt;L&gt;(string value, Func&lt;string, L&gt; coercer)
    {
        return coercer(value);
    }

    Coerce&lt;int&gt;("123", v =&gt; int.Parse(v));
</code></pre>

<p>This is fine however I also want to be able to write methods that override the behaviour for a specific type eg...</p>

<pre><code>    public int Coerce&lt;int&gt;(string value)
    {
        return Coerce&lt;int&gt;(value, v =&gt; int.Parse(v));
    }
</code></pre>

<p>So basically calling </p>

<pre><code>    Coerce&lt;int&gt;("123"); // equivalent Coerce&lt;int&gt;("123", v =&gt; int.Parse(v));
</code></pre>

<p>will save me having to re-write the int.Parse for every Coerce.  Of course this should then extend to handle</p>

<pre><code>    public decimal Coerce&lt;decimal&gt;(string value)
    {
        return Coerce&lt;decimal&gt;(value, v =&gt; int.Parse(v));
    }
</code></pre>

<p>Etc etc.</p>

<p>Can this be done neatly?</p>

<p>James</p>
