我想了解 struts 2 中的 paramsPrepareParamsStack 拦截器?
有文档链接之类的吗?
最佳答案
这是一个与 defaultStack 完全相同的堆栈,除了它在 prepare 拦截器之前包含一个额外的拦截器:params 拦截器
。
struts-default.xml
中的注释说了什么:
This is useful for when you wish to apply parameters directly to an object that you wish to load externally (such as a DAO or database or service layer), but can't load that object until at least the ID parameter has been loaded. By loading the parameters twice, you can retrieve the object in the prepare() method, allowing the second params interceptor to apply the values on the object.
详情请引用 interceptors .
关于java - struts2 中的paramsPrepareParamsStack 拦截器?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9453216/