<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Java and &#8220;multi-dispatch&#8221;</title>
	<atom:link href="http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/feed" rel="self" type="application/rss+xml" />
	<link>http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch</link>
	<description>Thoughts about the universe in general</description>
	<lastBuildDate>Sun, 20 May 2012 09:51:40 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4-alpha-19978</generator>
	<item>
		<title>By: Oren</title>
		<link>http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/comment-page-1#comment-122619</link>
		<dc:creator>Oren</dc:creator>
		<pubDate>Fri, 11 Jan 2008 20:16:06 +0000</pubDate>
		<guid isPermaLink="false">http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/#comment-122619</guid>
		<description>1.  lets start with reflection

    public void draw(Shape e)
    {
        try
        {
            Method method = SpecialCanvas.class.getMethod(&quot;draw&quot;,
                                                         e.getClass());
            return (String) method.invoke(this, e);
        }
        catch (java.lang.NoSuchMethodException noSuchMethodException)
        {
            // no need to log noSuchMethodException
            log.error(e);
;
        }
        catch (Exception e1)
        {
            log.error( e1);
            log.error(e);

        }
    }

I am not sure its that bad.
2. Regarding Generics I need to think it over.</description>
		<content:encoded><![CDATA[<p>1.  lets start with reflection</p>
<p>    public void draw(Shape e)<br />
    {<br />
        try<br />
        {<br />
            Method method = SpecialCanvas.class.getMethod(&#8220;draw&#8221;,<br />
                                                         e.getClass());<br />
            return (String) method.invoke(this, e);<br />
        }<br />
        catch (java.lang.NoSuchMethodException noSuchMethodException)<br />
        {<br />
            // no need to log noSuchMethodException<br />
            log.error(e);<br />
;<br />
        }<br />
        catch (Exception e1)<br />
        {<br />
            log.error( e1);<br />
            log.error(e);</p>
<p>        }<br />
    }</p>
<p>I am not sure its that bad.<br />
2. Regarding Generics I need to think it over.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Guss</title>
		<link>http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/comment-page-1#comment-122282</link>
		<dc:creator>Guss</dc:creator>
		<pubDate>Thu, 10 Jan 2008 13:49:32 +0000</pubDate>
		<guid isPermaLink="false">http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/#comment-122282</guid>
		<description>1. OUCH!
2. I&#039;m not sure how you&#039;d go about using generics to solve this issue - care to share an example ?</description>
		<content:encoded><![CDATA[<p>1. OUCH!<br />
2. I&#8217;m not sure how you&#8217;d go about using generics to solve this issue &#8211; care to share an example ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Oren</title>
		<link>http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/comment-page-1#comment-122259</link>
		<dc:creator>Oren</dc:creator>
		<pubDate>Thu, 10 Jan 2008 11:46:11 +0000</pubDate>
		<guid isPermaLink="false">http://geek.co.il/wp/2008/01/10/java-and-multi-dispatch/#comment-122259</guid>
		<description>There are sevarel solutions for this issue.
Use reflection to find the function (by its name or annotation).
you can also use common interface with generics.</description>
		<content:encoded><![CDATA[<p>There are sevarel solutions for this issue.<br />
Use reflection to find the function (by its name or annotation).<br />
you can also use common interface with generics.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

