com.bastengao.struts2.freeroute
类 Result

java.lang.Object
  继承者 com.bastengao.struts2.freeroute.Result
直接已知子类:
ChainResult, HttpHeaderResult, JsonResult, StreamResult

public class Result
extends Object

generic action result

从以下版本开始:
1.0
作者:
bastengao

字段摘要
protected  Map<String,String> params
           
protected  String resultType
           
 
构造方法摘要
protected Result()
          构造返回结果, resultType 默认为 "dispatcher"
protected Result(String resultType)
          构造返回结果
 
方法摘要
static Result create()
          构造返回结果, resultType 默认为 "dispatcher"
static Result create(String resultType)
          构造返回结果
 String done()
          完成
 Result location(String value)
          页面路径,如果有
 Result param(String name, String value)
          设置某个参数。
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

字段详细信息

params

protected Map<String,String> params

resultType

protected String resultType
构造方法详细信息

Result

protected Result()
构造返回结果, resultType 默认为 "dispatcher"

从以下版本开始:
1.0

Result

protected Result(String resultType)
构造返回结果

参数:
resultType - 返回结果类型
从以下版本开始:
1.0
方法详细信息

create

public static Result create()
构造返回结果, resultType 默认为 "dispatcher"

从以下版本开始:
1.0

create

public static Result create(String resultType)
构造返回结果

参数:
resultType - 返回结果类型
从以下版本开始:
1.0

param

public Result param(String name,
                    String value)
设置某个参数。可设置多次,如果重名会覆盖之前的值。

参数:
name - 参数名称
value - 值
返回:
从以下版本开始:
1.0

location

public Result location(String value)
页面路径,如果有

参数:
value -
返回:
从以下版本开始:
1.0

done

public String done()
完成

返回:
从以下版本开始:
1.0


Copyright © 2013 bastengao. All Rights Reserved.