「Struts2開発」アノテーション@Namespaceの使い方
Javaコード:
import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Namespace;
import com.opensymphony.xwork2.ActionSupport;
@Namespace(“/custom")
public class AnnoNameSpaceDemo extends ActionSupport {
@Action(“/startnews24/url")
public String execute() {
return SUCCESS;
}
@Action(“url")
public String doSomething() {
return SUCCESS;
}
}