package ActionDiffer;import java.text.DateFormat;
import java.util.Date;
![]()
import com.opensymphony.xwork2.ActionSupport;
![]()
public class ActionForStruts2 extends ActionSupport ...{
private String message;
![]()
public String getMessage() ...{
return message;
}
![]()
@Override
public String execute() ...{
message = " This is hello from strtuts2. Now is: " + DateFormat.getInstance().format( new Date());
return SUCCESS;
}
}
| 第1页: 引言 | 第2页: Action的区别 |
| 第3页: IoC | 第4页: 拦截器 |
| 第5页: Struts2和Struts1.x的全面比较 |