在xwork2.1.6版本中使用以下这段代码是没有错误的。
 
  ActionContext ctx = ActionContext.getContext();
  Map session = ctx.getSession();
  session.put(String, Object);
  
但在xwork2.0.7版本中就会出现null错误;
解决的方法:
 
     Map session = new HashMap(); 
     ActionContext.getContext().setSession(session); 
     session.put(String, Object);
 
 
 

相关文章:

  • 2022-12-23
  • 2021-06-08
  • 2022-12-23
  • 2022-12-23
  • 2021-09-26
  • 2022-12-23
猜你喜欢
  • 2021-09-01
  • 2021-07-06
  • 2021-10-18
  • 2021-07-31
  • 2022-12-23
  • 2022-12-23
  • 2022-01-09
相关资源
相似解决方案