日期:2014-05-17  浏览次数:20634 次

SSI整合时,spring注入失败
小妹初学Ibatis,SSI框架研究了N久后,开始试着搭建简单的小功能,但是访问时却报了空指针异常!!!

错误信息:
java.lang.NullPointerException

  com.action.UserAction.getAll(UserAction.java:32)
  sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  java.lang.reflect.Method.invoke(Method.java:597)
  com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:440)
  com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:279)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242)
  com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:163)
  com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:249)
  org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68)
  com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:122)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:195)
  com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:195)
  com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:148)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:93)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:235)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:89)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:128)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236)
  org.apache.struts2.interceptor.Profili