has an invalid setter method
2413 ワード
ここでconfig.xmlに新しいセグメントを追加します.
最初のヒント:
Bean property 'smsHistoryDao' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
長い間振り回されていたが、元のエラーはYCfacadeImplファイルにycDAOJDBCとycDAOHibernateにgetとsetメソッドがないことだった.
しかしgetとsetメソッドを設定しても無駄です.
またよく検索しました.
元はYCDAOHibernateImplとYCDAOJDBCImplの継承なのか古いインターフェースなのか、それを新しいインターフェースに変えればいいのです.
そうだconfig.xmlのいくつかの比較的良い文章:
1)http://helloaq.iteye.com/blog/218227 refを含む説明
2) http://hi.baidu.com/lynsahuang/blog/item/4dc04d3982de3123b9998fa4.html
3) http://hi.baidu.com/bigbig_88/blog/item/75ccc6a6e02376f99052eefc.html
4) http://www.cnblogs.com/hubcarl/archive/2011/04/28/2031711.html
<!--start yc -->
<bean id="ycDAOHibernate" class="com.vastis.ext.yc.dao.impl.YCDAOHibernateImpl">
<property name="sessionFactory">
<ref local="sessionFactory"/>
</property>
</bean>
<!--mssql -->
<bean id="ycDAOJDBC" class="com.vastis.ext.yc.dao.impl.YCDAOJDBCImpl">
<property name="dataSource">
<ref local="dataSource"/>
</property>
</bean>
<bean id="ycFacade" parent="JDBCDAOProxy">
<property name="target">
<bean class="com.vastis.ext.yc.service.impl.YCFacadeImpl">
<property name="ycDAOHibernate">
<ref bean="ycDAOHibernate"/>
</property>
<property name="ycDAOJDBC">
<ref bean="ycDAOJDBC"/>
</property>
</bean>
</property>
</bean>
<!--end yc-->
最初のヒント:
Bean property 'smsHistoryDao' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
長い間振り回されていたが、元のエラーはYCfacadeImplファイルにycDAOJDBCとycDAOHibernateにgetとsetメソッドがないことだった.
しかしgetとsetメソッドを設定しても無駄です.
またよく検索しました.
元はYCDAOHibernateImplとYCDAOJDBCImplの継承なのか古いインターフェースなのか、それを新しいインターフェースに変えればいいのです.
そうだconfig.xmlのいくつかの比較的良い文章:
1)http://helloaq.iteye.com/blog/218227 refを含む説明
2) http://hi.baidu.com/lynsahuang/blog/item/4dc04d3982de3123b9998fa4.html
3) http://hi.baidu.com/bigbig_88/blog/item/75ccc6a6e02376f99052eefc.html
4) http://www.cnblogs.com/hubcarl/archive/2011/04/28/2031711.html