我已将注释配置为将值作为文本返回。但它给了我错误:could not find action or result
.
控制台错误:
org.apache.struts2.dispatcher.Dispatcher - Could not find action or result
/part!finder.xhtml
No result defined for action action.PartAction and result success
行动:
@Action(value="part!finder", results = {
@Result(name="SUCCESS", type="stream", params = {"contentType", "text/html", "inputName", "inputStream"}),
@Result(name="success", type="stream", params = {"contentType", "text/html", "inputName", "inputStream"})
})
public String finder() {
try {
inputStream = new ByteArrayInputStream(finder1().getBytes());
}
catch(Exception e) { }
return SUCCESS;
}
}