Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyExce
2014-05-01 17:15
543 查看
Error setting property values ; nested exception is org.springframework.beans.NotWritablePropertyException
<!-- 添加一个dao类 -->
<bean id="tst" class="icmp.testdao">
<property name="SessionFactory">
<ref local="sessionFactory"/>
</property>
</bean>
<!-- 配置一个用户dao action 一定要注意这里的java类中(struts2demo类中声明了属性 private testdao tst; )的属性名字tst(局部变量名)必须和引用的bean 的名字的(ID)的名字相同-->
<bean id="demo2" class="st.struts2demo">
<property name="tst"><!-- 这里你随便用一个名字都错,必须是tst -->
<ref local="tst"/>
</property>
<!-- 坑了我好半天 -->
</bean>
<!-- 添加一个dao类 -->
<bean id="tst" class="icmp.testdao">
<property name="SessionFactory">
<ref local="sessionFactory"/>
</property>
</bean>
<!-- 配置一个用户dao action 一定要注意这里的java类中(struts2demo类中声明了属性 private testdao tst; )的属性名字tst(局部变量名)必须和引用的bean 的名字的(ID)的名字相同-->
<bean id="demo2" class="st.struts2demo">
<property name="tst"><!-- 这里你随便用一个名字都错,必须是tst -->
<ref local="tst"/>
</property>
<!-- 坑了我好半天 -->
</bean>
相关文章推荐
- Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyExce
- Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyExc
- Spring 整合 Flex (BlazeDS)无法从as对象 到 Java对象转换的异常:org.springframework.beans.ConversionNotSupportedException: Failed to convert property value of type 'java.util.Date' to required type 'java.sql.Timestamp' for property 'wfsj'; nested exception is java.lang.Ill
- nested exception is org.springframework.beans.NotWritablePropertyException:
- nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add
- Error creating bean with name 'userService': Injection of resource methods failed; nested exception is org.springframework.beans
- Error creating bean with name 'userService': Injection of resource methods failed; nested exception is org.springframework.beans
- nested exception is org.springframework.beans.ConversionNotSupportedException的解决方法
- nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '(inner bean)#1': Can
- org.springframework.dao.InvalidDataAccessResourceUsageException: could not execute query; nested exception is org.hibernate.exce
- 错误提示:org.springframework.beans.NotWritablePropertyException: Invalid property
- SpringBoot启动报错" Unable to start embedded container; nested exception is org.springframework.beans.fa
- org.springframework.beans.NotWritablePropertyException: Invalid property... 问题解决
- jpa语句报 org.springframework.dao.InvalidDataAccessApiUsageException: Parameter with that position [2] did not exist; nested exception is java.lang.IllegalArgumentException: Parameter with that position
- ?--Porg.springframework.beans.MethodInvocationException: Property 'username' threw exception; nested exception is java.lang.NullPointerException
- Spring MVC集成thymeleaf时提示:defined in ServletContext resource [/WEB-INF/SrpingMVCTest-servlet.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException
- nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException
- Caused by: org.springframework.beans.NullValueInNestedPathException: Invalid property 'xxxx'
- Initialization of bean failed; nested exception is org.springframework.beans.factory.: 错误分析
- org.springframework.dao.DataIntegrityViolationException: could not execute statement; SQL [n/a]; constraint [null]; nested exception is org.hibernate.