org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loginservice' defined in class path resource [applicationContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cx.service.LoginServiceImpl]: Constructor threw exception; nested exception is java.lang.Error: Unresolved compilation problems:  The import org.springframework cannot be resolved HibernateDaoSupport cannot be resolved to a type The method getHibernateTemplate() is undefined for the type LoginServiceImpl

oschina.net | 5 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    开源中国(OSChina.NET)

    oschina.net | 5 months ago
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loginservice' defined in class path resource [applicationContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cx.service.LoginServiceImpl]: Constructor threw exception; nested exception is java.lang.Error: Unresolved compilation problems:  The import org.springframework cannot be resolved HibernateDaoSupport cannot be resolved to a type The method getHibernateTemplate() is undefined for the type LoginServiceImpl
  2. 0

    ¡¾mavnÏîÄ¿Æô¶¯±¨´í¡¿-ÎÊ´ð·ÖÏí-ÎÊ´ð·ÖÏí-Õæ¸ñѧÍø-IT¼¼Êõ×ÛºÏÍøÕ¾

    zgxue.com | 5 months ago
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loginservice' defined in class path resource [applicationContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cx.service.LoginServiceImpl]: Constructor threw exception; nested exception is java.lang.Error: Unresolved compilation problems:  The import org.springframework cannot be resolved HibernateDaoSupport cannot be resolved to a type The method getHibernateTemplate() is undefined for the type LoginServiceImpl

    Root Cause Analysis

    1. java.lang.Error

      Unresolved compilation problems:  The import org.springframework cannot be resolved HibernateDaoSupport cannot be resolved to a type The method getHibernateTemplate() is undefined for the type LoginServiceImpl

      at cx.service.LoginServiceImpl.<init>()
    2. cx.service
      LoginServiceImpl.<init>
      1. cx.service.LoginServiceImpl.<init>(LoginServiceImpl.java:4)
      1 frame
    3. Java RT
      Constructor.newInstance
      1. sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      2. sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
      3. sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
      4. java.lang.reflect.Constructor.newInstance(Constructor.java:513)
      4 frames
    4. Spring Beans
      BeanUtils.instantiateClass
      1. org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
      1 frame