org.springframework.beans.NotWritablePropertyException: Invalid property 'userDao' of bean class [com.pb.service.WangZhanServiceImpl]: Bean property 'userDao' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
好像是在配置applicationContext.xml文件时,向wangZhanService中注入userDao时出错,百度上说是userDao这个词写错,但我检查了,好像没错。暂时没准确答案!!
找到问题了!!我的是因为在WangZhanServiceImpl中没有写userDao的set方法!!写上之后异常消失!