I'm working on Struts 2 web application, using the Convention Plugin to configure everything via annotations. I'm hitting a snag with some of my action classes, where I'd like to use multiple parent packages. I did find a means of doing it on Apache's site - but that appears to be deprecated. It does not work, throwing back a Type mismatch: cannot convert from String[]
to String
error.
@ParentPackage({"my-parent-package1, my-parent-package2"})
package com.mycompany.myapp.actions
import org.apache.struts2.config.ParentPackage;
I am using Struts 2.2.1. Is it possible to grant an action multiple parent packages via annotations? Seems odd that they would have removed this as a feature.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…