<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Supple software comments on Spring's autowire by type and inheritance</title>
    <link>http://supplesoftware.com/</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Supple software comments</description>
    <item>
      <title>"Spring's autowire by type and inheritance" by petrovg</title>
      <description>&lt;p&gt;It seems that if a Spring context contains a class (A) and its superclass (B), the autowire by type for the superclass (B) fails.&lt;/p&gt;

&lt;p&gt;That&amp;#8217;s because when it does the lookup for beans of type B, the context returns both B and A. It&amp;#8217;s not wrong in any way, it&amp;#8217;s probably exactly the right thing to do, but it somehow makes it a bit trickier to do tests well, for me now anyway&amp;#8230;.&lt;/p&gt;

&lt;p&gt;Or, may be one should never instantiate classes which are not leafs of the hierarchy tree. Should may be all classes that can be extended be abstract?&amp;#8230;. All non-final classes abstract&amp;#8230;hm&amp;#8230; weird thoughts, don&amp;#8217;t pay too much attention&amp;#8230;..&lt;/p&gt;

</description>
      <pubDate>Tue, 20 Feb 2007 05:22:55 PST</pubDate>
      <guid>&lt;a href="/articles/2007/02/20/springs-autowire-by-type-and-inheritance"&gt;Spring's autowire by type and inheritance&lt;/a&gt;</guid>
      <link>&lt;a href="/articles/2007/02/20/springs-autowire-by-type-and-inheritance"&gt;Spring's autowire by type and inheritance&lt;/a&gt;</link>
    </item>
  </channel>
</rss>
