構成とのspring bean両方を使用して定義されている場合。次に、優先度の高い初期化中、または.xmlannotationxmlannotations
私の豆のように...
package com.abc;
@Component
Class Demo{
...
}
そして、私のxml構成は...
...
<context:annotation-config />
<context:component-scan base-package="com.abc" />
<bean id="demo" class="com.abc.Demo"/>
...
これで、demoBean は と の両方xmlを使用して定義されannotationsます。初期化中、誰がbean:annotationまたはxml.